gc2145_settings.h 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719
  1. #include <stdint.h>
  2. #define REG_DLY 0xffff
  3. #define REGLIST_TAIL 0x0000 /* Array end token */
  4. static const uint16_t gc2145_default_init_regs[][2] = {
  5. {0xfe, 0xf0},
  6. {0xfe, 0xf0},
  7. {0xfe, 0xf0},
  8. {0xfc, 0x06},
  9. {0xf6, 0x00},
  10. {0xf7, 0x1d}, //37 //17 //37 //1d//05
  11. {0xf8, 0x83}, //87 //83 //82
  12. {0xfa, 0x00},
  13. {0xf9, 0xfe}, //ff
  14. {0xfd, 0x00},
  15. {0xc2, 0x00},
  16. {0xf2, 0x0f},
  17. //////////////////////////////////////////////////////
  18. //////////////////// Analog & Cisctl ////////////////
  19. //////////////////////////////////////////////////////
  20. {0xfe, 0x00},
  21. {0x03, 0x04}, //exp time
  22. {0x04, 0x62}, //exp time
  23. {0x05, 0x01}, //00 //hb[11:8]
  24. {0x06, 0x3b}, //0b //hb
  25. {0x09, 0x00}, //row start
  26. {0x0a, 0x00}, //
  27. {0x0b, 0x00}, //col start
  28. {0x0c, 0x00},
  29. {0x0d, 0x04}, //height
  30. {0x0e, 0xc0},
  31. {0x0f, 0x06}, //width
  32. {0x10, 0x52},
  33. {0x12, 0x2e}, //sh_delay 太短 YUV出图异常
  34. {0x17, 0x14}, //CISCTL Mode1 [1:0]mirror flip
  35. {0x18, 0x22}, //sdark mode
  36. {0x19, 0x0f}, // AD pipe number
  37. {0x1a, 0x01}, //AD manual switch mode
  38. {0x1b, 0x4b}, //48 restg Width,SH width
  39. {0x1c, 0x07}, //06 帧率快后,横条纹 //12 //TX Width,Space Width
  40. {0x1d, 0x10}, //double reset
  41. {0x1e, 0x88}, //90//98 //fix 竖线//Analog Mode1,TX high,Coln_r
  42. {0x1f, 0x78}, //78 //38 //18 //Analog Mode2,txlow
  43. {0x20, 0x03}, //07 //Analog Mode3,comv,ad_clk mode
  44. {0x21, 0x40}, //10//20//40 //fix 灯管横条纹
  45. {0x22, 0xa0}, //d0//f0 //a2 //Vref vpix FPN严重
  46. {0x24, 0x1e},
  47. {0x25, 0x01}, //col sel
  48. {0x26, 0x10}, //Analog PGA gain1
  49. {0x2d, 0x60}, //40//40 //txl drv mode
  50. {0x30, 0x01}, //Analog Mode4
  51. {0x31, 0x90}, //b0//70 // Analog Mode7 [7:5]rsgh_r灯管横条纹[4:3]isp_g
  52. {0x33, 0x06}, //03//02//01 //EQ_hstart_width
  53. {0x34, 0x01},
  54. //
  55. ///////////////////////////////////////////////////
  56. //////////////////// ISP reg //////////////////////
  57. //////////////////////////////////////////////////////
  58. {0x80, 0xff}, //outdoor gamma_en, GAMMA_en, CC_en, EE_en, INTP_en, DN_en, DD_en,LSC_en
  59. {0x81, 0x24}, //26//24 //BLK dither mode, ll_y_en ,skin_en, edge SA, new_skin_mode, autogray_en,ll_gamma_en,BFF test image
  60. {0x82, 0xfa}, //FA //auto_SA, auto_EE, auto_DN, auto_DD, auto_LSC, ABS_en, AWB_en, NA
  61. {0x83, 0x00}, //special_effect
  62. {0x84, 0x02}, //output format
  63. {0x86, 0x03}, //c2 //46 //c2 //sync mode
  64. {0x88, 0x03}, //[1]ctl_auto_gating [0]out_auto_gating
  65. {0x89, 0x03}, //bypass disable
  66. {0x85, 0x30}, //60//frame start cut
  67. {0x8a, 0x00}, //ISP_quiet_mode,close aaa pclk,BLK gate mode,exception,close first pipe clock,close dndd clock,close intp clock,DIV_gatedclk_en
  68. {0x8b, 0x00}, //[7:6]BFF_gate_mode,[5]BLK switch gain,[4]protect exp,[3:2]pipe gate mode,[1]not split sram,[0]dark current update
  69. {0xb0, 0x55}, //60 //global gain
  70. {0xc3, 0x00}, //[7:4]auto_exp_gamma_th1[11:8],[3:0]auto_exp_gamma_th2[11:8]
  71. {0xc4, 0x80}, //auto_exp_gamma_th1[7:0] into
  72. {0xc5, 0x90}, //auto_exp_gamma_th2[7:0] out //outdoor gamma
  73. {0xc6, 0x38}, //auto_gamma_th1
  74. {0xc7, 0x40}, //auto_gamma_th2
  75. {0xec, 0x06}, //measure window
  76. {0xed, 0x04},
  77. {0xee, 0x60}, //16 col
  78. {0xef, 0x90}, //8 row
  79. {0xb6, 0x01}, //[0]aec en
  80. {0x90, 0x01}, //crop
  81. {0x91, 0x00},
  82. {0x92, 0x00},
  83. {0x93, 0x00},
  84. {0x94, 0x00}, //08
  85. {0x95, 0x04},
  86. {0x96, 0xb0},
  87. {0x97, 0x06},
  88. {0x98, 0x40},
  89. ///////////////////////////////////////////////
  90. /////////// BLK ////////////////////////
  91. ///////////////////////////////////////////////
  92. {0x18, 0x02},
  93. {0x40, 0x42}, //2b //27
  94. {0x41, 0x00}, //80 //dark row sel
  95. {0x43, 0x54}, //[7:4]BLK start not smooth [3:0]output start frame
  96. {0x5e, 0x00}, //00//10 //18
  97. {0x5f, 0x00}, //00//10 //18
  98. {0x60, 0x00}, //00//10 //18
  99. {0x61, 0x00}, //00///10 //18
  100. {0x62, 0x00}, //00//10 //18
  101. {0x63, 0x00}, //00//10 //18
  102. {0x64, 0x00}, //00/10 //18
  103. {0x65, 0x00}, //00//10 //18
  104. {0x66, 0x20}, //1e
  105. {0x67, 0x20}, //1e
  106. {0x68, 0x20}, //1e
  107. {0x69, 0x20}, //1e
  108. {0x76, 0x00}, //0f
  109. {0x6a, 0x00}, //06
  110. {0x6b, 0x00}, //06
  111. {0x6c, 0x3e}, //06
  112. {0x6d, 0x3e}, //06
  113. {0x6e, 0x3f}, //06
  114. {0x6f, 0x3f}, //06
  115. {0x70, 0x00}, //06
  116. {0x71, 0x00}, //06 //manual offset
  117. {0x76, 0x00}, //1f//add offset
  118. {0x72, 0xf0}, //[7:4]BLK DD th [3:0]BLK various th
  119. {0x7e, 0x3c}, //ndark
  120. {0x7f, 0x00},
  121. {0xfe, 0x02},
  122. {0x48, 0x15},
  123. {0x49, 0x00}, //04//04 //ASDE OFFSET SLOPE
  124. {0x4b, 0x0b}, //ASDE y OFFSET SLOPE
  125. {0xfe, 0x00},
  126. ///////////////////////////////////////////////
  127. /////////// AEC ////////////////////////
  128. ///////////////////////////////////////////////
  129. {0xfe, 0x01},
  130. {0x01, 0x04}, //AEC X1
  131. {0x02, 0xc0}, //AEC X2
  132. {0x03, 0x04}, //AEC Y1
  133. {0x04, 0x90}, //AEC Y2
  134. {0x05, 0x30}, //20 //AEC center X1
  135. {0x06, 0x90}, //40 //AEC center X2
  136. {0x07, 0x20}, //30 //AEC center Y1
  137. {0x08, 0x70}, //60 //AEC center Y2
  138. {0x09, 0x00}, //AEC show mode
  139. {0x0a, 0xc2}, //[7]col gain enable
  140. {0x0b, 0x11}, //AEC every N
  141. {0x0c, 0x10}, //AEC_mode3 center weight
  142. {0x13, 0x40}, //2a //AEC Y target
  143. {0x17, 0x00}, //AEC ignore mode
  144. {0x1c, 0x11}, //
  145. {0x1e, 0x61}, //
  146. {0x1f, 0x30}, //40//50 //max pre gain
  147. {0x20, 0x40}, //60//40 //max post gain
  148. {0x22, 0x80}, //AEC outdoor THD
  149. {0x23, 0x20}, //target_Y_low_limit
  150. {0xfe, 0x02},
  151. {0x0f, 0x04}, //05
  152. {0xfe, 0x01},
  153. {0x12, 0x35}, //35 //[5:4]group_size [3]slope_disable [2]outdoor_enable [0]histogram_enable
  154. {0x15, 0x50}, //target_Y_high_limit
  155. {0x10, 0x31}, //num_thd_high
  156. {0x3e, 0x28}, //num_thd_low
  157. {0x3f, 0xe0}, //luma_thd
  158. {0x40, 0x20}, //luma_slope
  159. {0x41, 0x0f}, //color_diff
  160. {0xfe, 0x02},
  161. {0x0f, 0x05}, //max_col_level
  162. ///////////////////////////
  163. ////// INTPEE /////////////
  164. ///////////////////////////
  165. {0xfe, 0x02}, //page2
  166. {0x90, 0x6c}, //ac //eeintp mode1
  167. {0x91, 0x03}, //02 ////eeintp mode2
  168. {0x92, 0xc8}, //44 //low criteria for direction
  169. {0x94, 0x66},
  170. {0x95, 0xb5},
  171. {0x97, 0x64}, //78 ////edge effect
  172. {0xa2, 0x11}, //fix direction
  173. {0xfe, 0x00},
  174. /////////////////////////////
  175. //////// DNDD///////////////
  176. /////////////////////////////
  177. {0xfe, 0x02},
  178. {0x80, 0xc1}, //c1 //[7]share mode [6]skin mode [5]is 5x5 mode [1:0]noise value select 0:2 1:2.5 2:3 3:4
  179. {0x81, 0x08}, //
  180. {0x82, 0x08}, //signal a 0.6
  181. {0x83, 0x08}, //04 //signal b 2.5
  182. {0x84, 0x0a}, //10 //05 dark_DD_TH
  183. {0x86, 0xf0}, //a0 Y_value_dd_th2
  184. {0x87, 0x50}, //90 Y_value_dd_th3
  185. {0x88, 0x15}, //60 Y_value_dd_th4
  186. {0x89, 0x50}, //80 // asde th2
  187. {0x8a, 0x30}, //60 // asde th3
  188. {0x8b, 0x10}, //30 // asde th4
  189. /////////////////////////////////////////////////
  190. ///////////// ASDE ////////////////////////
  191. /////////////////////////////////////////////////
  192. {0xfe, 0x01}, //page 1
  193. {0x21, 0x14}, //luma_value_div_sel(分频,与0xef呈2倍关系,增大1,0xef的值减小1倍)
  194. //ff ef luma_value read_only
  195. {0xfe, 0x02}, //page2
  196. {0xa3, 0x40}, //ASDE_low_luma_value_LSC_th_H
  197. {0xa4, 0x20}, //ASDE_low_luma_value_LSC_th_L
  198. {0xa5, 0x40}, //80 //ASDE_LSC_gain_dec_slope_H
  199. {0xa6, 0x80}, // 80 //ASDE_LSC_gain_dec_slope_L
  200. //ff a7 ASDE_LSC_gain_dec //read only
  201. {0xab, 0x40}, //50 //ASDE_low_luma_value_OT_th
  202. {0xae, 0x0c}, //[3]EE1_effect_inc_or_dec_high,[2]EE2_effect_inc_or_dec_high,
  203. //[1]EE1_effect_inc_or_dec_low,[0]EE2_effect_inc_or_dec_low, 1:inc 0:dec
  204. {0xb3, 0x34}, //44 //ASDE_EE1_effect_slope_low,ASDE_EE2_effect_slope_low
  205. {0xb4, 0x44}, //12 //ASDE_EE1_effect_slope_high,ASDE_EE2_effect_slope_high
  206. {0xb6, 0x38}, //40//40 //ASDE_auto_saturation_dec_slope
  207. {0xb7, 0x02}, //04 //ASDE_sub_saturation_slope
  208. {0xb9, 0x30}, //[7:0]ASDE_auto_saturation_low_limit
  209. {0x3c, 0x08}, //[3:0]auto gray_dec_slope
  210. {0x3d, 0x30}, //[7:0]auto gray_dec_th
  211. {0x4b, 0x0d}, //y offset slope
  212. {0x4c, 0x20}, //y offset limit
  213. {0xfe, 0x00},
  214. //
  215. ///////////////////gamma1////////////////////
  216. ////Gamma
  217. {0xfe, 0x02},
  218. {0x10, 0x10},
  219. {0x11, 0x15},
  220. {0x12, 0x1a},
  221. {0x13, 0x1f},
  222. {0x14, 0x2c},
  223. {0x15, 0x39},
  224. {0x16, 0x45},
  225. {0x17, 0x54},
  226. {0x18, 0x69},
  227. {0x19, 0x7d},
  228. {0x1a, 0x8f},
  229. {0x1b, 0x9d},
  230. {0x1c, 0xa9},
  231. {0x1d, 0xbd},
  232. {0x1e, 0xcd},
  233. {0x1f, 0xd9},
  234. {0x20, 0xe3},
  235. {0x21, 0xea},
  236. {0x22, 0xef},
  237. {0x23, 0xf5},
  238. {0x24, 0xf9},
  239. {0x25, 0xff},
  240. /////auto gamma/////
  241. {0xfe, 0x02},
  242. {0x26, 0x0f},
  243. {0x27, 0x14},
  244. {0x28, 0x19},
  245. {0x29, 0x1e},
  246. {0x2a, 0x27},
  247. {0x2b, 0x33},
  248. {0x2c, 0x3b},
  249. {0x2d, 0x45},
  250. {0x2e, 0x59},
  251. {0x2f, 0x69},
  252. {0x30, 0x7c},
  253. {0x31, 0x89},
  254. {0x32, 0x98},
  255. {0x33, 0xae},
  256. {0x34, 0xc0},
  257. {0x35, 0xcf},
  258. {0x36, 0xda},
  259. {0x37, 0xe2},
  260. {0x38, 0xe9},
  261. {0x39, 0xf3},
  262. {0x3a, 0xf9},
  263. {0x3b, 0xff},
  264. ///////////////////////////////////////////////
  265. /////////// YCP ///////////////////////
  266. ///////////////////////////////////////////////
  267. {0xfe, 0x02},
  268. {0xd1, 0x30}, //32 //
  269. {0xd2, 0x30}, //32 //
  270. {0xd3, 0x45},
  271. {0xdd, 0x14}, //edge sa
  272. {0xde, 0x86}, //asde auto gray
  273. {0xed, 0x01}, //
  274. {0xee, 0x28},
  275. {0xef, 0x30},
  276. {0xd8, 0xd8}, //autogray protecy
  277. ////////////////////////////
  278. //////// LSC 0.8///////////////
  279. ////////////////////////////
  280. {0xfe, 0x01},
  281. {0xa1, 0x80}, // center_row
  282. {0xa2, 0x80}, // center_col
  283. {0xa4, 0x00}, // sign of b1
  284. {0xa5, 0x00}, // sign of b1
  285. {0xa6, 0x70}, // sign of b4
  286. {0xa7, 0x00}, // sign of b4
  287. {0xa8, 0x77}, // sign of b22
  288. {0xa9, 0x77}, // sign of b22
  289. {0xaa, 0x1f}, // Q1_b1 of R
  290. {0xab, 0x0d}, // Q1_b1 of G
  291. {0xac, 0x19}, // Q1_b1 of B
  292. {0xad, 0x24}, // Q2_b1 of R
  293. {0xae, 0x0e}, // Q2_b1 of G
  294. {0xaf, 0x1d}, // Q2_b1 of B
  295. {0xb0, 0x12}, // Q3_b1 of R
  296. {0xb1, 0x0c}, // Q3_b1 of G
  297. {0xb2, 0x06}, // Q3_b1 of B
  298. {0xb3, 0x13}, // Q4_b1 of R
  299. {0xb4, 0x10}, // Q4_b1 of G
  300. {0xb5, 0x0c}, // Q4_b1 of B
  301. {0xb6, 0x6a}, // right_b2 of R
  302. {0xb7, 0x46}, // right_b2 of G
  303. {0xb8, 0x40}, // right_b2 of B
  304. {0xb9, 0x0b}, // right_b4 of R
  305. {0xba, 0x04}, // right_b4 of G
  306. {0xbb, 0x00}, // right_b4 of B
  307. {0xbc, 0x53}, // left_b2 of R
  308. {0xbd, 0x37}, // left_b2 of G
  309. {0xbe, 0x2d}, // left_b2 of B
  310. {0xbf, 0x0a}, // left_b4 of R
  311. {0xc0, 0x0a}, // left_b4 of G
  312. {0xc1, 0x14}, // left_b4 of B
  313. {0xc2, 0x34}, // up_b2 of R
  314. {0xc3, 0x22}, // up_b2 of G
  315. {0xc4, 0x18}, // up_b2 of B
  316. {0xc5, 0x23}, // up_b4 of R
  317. {0xc6, 0x0f}, // up_b4 of G
  318. {0xc7, 0x3c}, // up_b4 of B
  319. {0xc8, 0x20}, // down_b2 of R
  320. {0xc9, 0x1f}, // down_b2 of G
  321. {0xca, 0x17}, // down_b2 of B
  322. {0xcb, 0x2d}, // down_b4 of R
  323. {0xcc, 0x12}, // down_b4 of G
  324. {0xcd, 0x20}, // down_b4 of B
  325. {0xd0, 0x61}, // right_up_b22 of R
  326. {0xd1, 0x2f}, // right_up_b22 of G
  327. {0xd2, 0x39}, // right_up_b22 of B
  328. {0xd3, 0x45}, // right_down_b22 of R
  329. {0xd4, 0x2c}, // right_down_b22 of G
  330. {0xd5, 0x21}, // right_down_b22 of B
  331. {0xd6, 0x64}, // left_up_b22 of R
  332. {0xd7, 0x2d}, // left_up_b22 of G
  333. {0xd8, 0x30}, // left_up_b22 of B
  334. {0xd9, 0x42}, // left_down_b22 of R
  335. {0xda, 0x27}, // left_down_b22 of G
  336. {0xdb, 0x13}, // left_down_b22 of B
  337. {0xfe, 0x00},
  338. /////////////////////////////////////////////////
  339. ///////////// AWB ////////////////////////
  340. /////////////////////////////////////////////////
  341. {0xfe, 0x01},
  342. {0x4f, 0x00},
  343. {0x4f, 0x00},
  344. {0x4b, 0x01},
  345. {0x4f, 0x00},
  346. {0x4c, 0x01},
  347. {0x4d, 0x6f},
  348. {0x4e, 0x02},
  349. {0x4c, 0x01},
  350. {0x4d, 0x70},
  351. {0x4e, 0x02},
  352. {0x4c, 0x01},
  353. {0x4d, 0x8f},
  354. {0x4e, 0x02},
  355. {0x4c, 0x01},
  356. {0x4d, 0x90},
  357. {0x4e, 0x02}, //light
  358. {0x4c, 0x01},
  359. {0x4d, 0xed},
  360. {0x4e, 0x33}, //light
  361. {0x4c, 0x01},
  362. {0x4d, 0xcd},
  363. {0x4e, 0x33}, //light
  364. {0x4c, 0x01},
  365. {0x4d, 0xec},
  366. {0x4e, 0x03}, //light
  367. {0x4c, 0x01},
  368. {0x4d, 0x6c},
  369. {0x4e, 0x03},
  370. {0x4c, 0x01},
  371. {0x4d, 0x6d},
  372. {0x4e, 0x03},
  373. {0x4c, 0x01},
  374. {0x4d, 0x6e},
  375. {0x4e, 0x03},
  376. {0x4c, 0x01},
  377. {0x4d, 0x8c},
  378. {0x4e, 0x03},
  379. {0x4c, 0x01},
  380. {0x4d, 0x8d},
  381. {0x4e, 0x03},
  382. {0x4c, 0x01},
  383. {0x4d, 0x8e},
  384. {0x4e, 0x03},
  385. {0x4c, 0x01},
  386. {0x4d, 0xab},
  387. {0x4e, 0x03},
  388. {0x4c, 0x01},
  389. {0x4d, 0xac},
  390. {0x4e, 0x03},
  391. {0x4c, 0x01},
  392. {0x4d, 0xad},
  393. {0x4e, 0x03},
  394. {0x4c, 0x01},
  395. {0x4d, 0xae},
  396. {0x4e, 0x03},
  397. {0x4c, 0x01},
  398. {0x4d, 0xcb},
  399. {0x4e, 0x03},
  400. {0x4c, 0x01},
  401. {0x4d, 0xcc},
  402. {0x4e, 0x03},
  403. {0x4c, 0x01},
  404. {0x4d, 0xce},
  405. {0x4e, 0x03},
  406. {0x4c, 0x01},
  407. {0x4d, 0xeb},
  408. {0x4e, 0x03},
  409. {0x4c, 0x01},
  410. {0x4d, 0xec},
  411. {0x4e, 0x03},
  412. {0x4c, 0x01},
  413. {0x4d, 0xee},
  414. {0x4e, 0x03},
  415. {0x4c, 0x02},
  416. {0x4d, 0x0c},
  417. {0x4e, 0x03},
  418. {0x4c, 0x02},
  419. {0x4d, 0x0d},
  420. {0x4e, 0x03},
  421. {0x4c, 0x01},
  422. {0x4d, 0xea},
  423. {0x4e, 0x03},
  424. {0x4c, 0x01},
  425. {0x4d, 0xaf},
  426. {0x4e, 0x03}, //dark
  427. {0x4c, 0x01},
  428. {0x4d, 0xcf},
  429. {0x4e, 0x03}, //dark
  430. {0x4c, 0x01},
  431. {0x4d, 0xca},
  432. {0x4e, 0x04}, //light
  433. {0x4c, 0x02},
  434. {0x4d, 0x0b},
  435. {0x4e, 0x05}, //light
  436. {0x4c, 0x02},
  437. {0x4d, 0xc8},
  438. {0x4e, 0x06}, //light 100lux
  439. {0x4c, 0x02},
  440. {0x4d, 0xa8},
  441. {0x4e, 0x06}, //light
  442. {0x4c, 0x02},
  443. {0x4d, 0xa9},
  444. {0x4e, 0x06}, //light
  445. {0x4c, 0x02},
  446. {0x4d, 0x89},
  447. {0x4e, 0x06}, //400lux
  448. {0x4c, 0x02},
  449. {0x4d, 0x69},
  450. {0x4e, 0x06}, //f12
  451. {0x4c, 0x02},
  452. {0x4d, 0x6a},
  453. {0x4e, 0x06}, //f12
  454. {0x4c, 0x02},
  455. {0x4d, 0xc7},
  456. {0x4e, 0x07},
  457. {0x4c, 0x02},
  458. {0x4d, 0xe7},
  459. {0x4e, 0x07}, //100lux
  460. {0x4c, 0x03},
  461. {0x4d, 0x07},
  462. {0x4e, 0x07}, //light
  463. {0x4c, 0x02},
  464. {0x4d, 0xe8},
  465. {0x4e, 0x07},
  466. {0x4c, 0x02},
  467. {0x4d, 0xe9},
  468. {0x4e, 0x07},
  469. {0x4c, 0x03},
  470. {0x4d, 0x08},
  471. {0x4e, 0x07},
  472. {0x4c, 0x03},
  473. {0x4d, 0x09},
  474. {0x4e, 0x07},
  475. {0x4c, 0x03},
  476. {0x4d, 0x27},
  477. {0x4e, 0x07},
  478. {0x4c, 0x03},
  479. {0x4d, 0x28},
  480. {0x4e, 0x07},
  481. {0x4c, 0x03},
  482. {0x4d, 0x29},
  483. {0x4e, 0x07},
  484. {0x4c, 0x03},
  485. {0x4d, 0x47},
  486. {0x4e, 0x07},
  487. {0x4c, 0x03},
  488. {0x4d, 0x48},
  489. {0x4e, 0x07},
  490. {0x4c, 0x03},
  491. {0x4d, 0x49},
  492. {0x4e, 0x07},
  493. {0x4c, 0x03},
  494. {0x4d, 0x67},
  495. {0x4e, 0x07},
  496. {0x4c, 0x03},
  497. {0x4d, 0x68},
  498. {0x4e, 0x07},
  499. {0x4c, 0x03},
  500. {0x4d, 0x69},
  501. {0x4e, 0x07},
  502. {0x4f, 0x01},
  503. {0xfe, 0x01},
  504. {0x50, 0x80}, //AWB_PRE_mode
  505. {0x51, 0xa8}, //AWB_pre_THD_min[7:0]
  506. {0x52, 0x57}, //AWB_pre_THD_min[15:8] Dominiate luma 0.25=639c 0.22=57a8
  507. {0x53, 0x38}, //AWB_pre_THD_min_MIX[7:0]
  508. {0x54, 0xc7}, //AWB_pre_THD_min_MIX[15:8] Mix luma 0.5
  509. {0x56, 0x0e}, //AWB_tone mode
  510. {0x58, 0x08}, //AWB_C_num_sel,AWB_D_num_sel
  511. {0x5b, 0x00}, //AWB_mix_mode
  512. {0x5c, 0x74}, //green_num0[7:0]
  513. {0x5d, 0x8b}, //green_num0[15:8] 0.35
  514. {0x61, 0xd3}, //R2G_stand0
  515. {0x62, 0xb5}, //B2G_stand0
  516. {0x63, 0x00}, //88//a4 //AWB gray mode [7]enable
  517. {0x65, 0x04}, //AWB margin
  518. {0x67, 0xb2}, //R2G_stand3[7:0] FF/CWF
  519. {0x68, 0xac}, //B2G_stand3[7:0]
  520. {0x69, 0x00}, //R2G_stand4[9:8] B2G_stand4[9:8] R2G_stand3[9:8] B2G_stand3[9:8]
  521. {0x6a, 0xb2}, //R2G_stand4[7:0] TL84/TL84&CWF
  522. {0x6b, 0xac}, //B2G_stand4[7:0]
  523. {0x6c, 0xb2}, //R2G_stand5[7:0] A
  524. {0x6d, 0xac}, //B2G_stand5[7:0]
  525. {0x6e, 0x40}, //AWB_skin_weight R2G_stand5[9:8] B2G_stand5[9:8]
  526. {0x6f, 0x18}, //AWB_indoor_THD (0x21=17 caculate)
  527. {0x73, 0x00}, //AWB_indoor_mode
  528. {0x70, 0x10}, //AWB low luma TH
  529. {0x71, 0xe8}, //AWB outdoor TH
  530. {0x72, 0xc0}, //outdoor mode
  531. {0x74, 0x01}, //[2:0]AWB skip mode 2x2,4x4,4x8,8x8
  532. {0x75, 0x01}, //[1:0]AWB_every_N
  533. {0x7f, 0x08}, //[3]gray world frame start
  534. {0x76, 0x70}, //R limit
  535. {0x77, 0x58}, //G limit
  536. {0x78, 0xa0}, //d8 //B limit
  537. {0xfe, 0x00},
  538. //
  539. //////////////////////////////////////////
  540. /////////// CC ////////////////////////
  541. //////////////////////////////////////////
  542. {0xfe, 0x02},
  543. {0xc0, 0x01}, //[5:4] CC mode [0]CCT enable
  544. {0xC1, 0x50}, //D50/D65
  545. {0xc2, 0xF9},
  546. {0xc3, 0x00}, //0
  547. {0xc4, 0xe8}, //e0
  548. {0xc5, 0x48},
  549. {0xc6, 0xf0},
  550. {0xC7, 0x50},
  551. {0xc8, 0xf2},
  552. {0xc9, 0x00},
  553. {0xcA, 0xE0},
  554. {0xcB, 0x45},
  555. {0xcC, 0xec},
  556. {0xCd, 0x45},
  557. {0xce, 0xf0},
  558. {0xcf, 0x00},
  559. {0xe3, 0xf0},
  560. {0xe4, 0x45},
  561. {0xe5, 0xe8},
  562. {0xfe, 0x00},
  563. {0xf2, 0x0f},
  564. //////////////frame rate 50Hz
  565. {0xfe, 0x00},
  566. {0xf7, 0x1d},
  567. {0xf8, 0x84},
  568. {0xfa, 0x00},
  569. {0x05, 0x01}, //hb
  570. {0x06, 0x3b},
  571. {0x07, 0x01}, //Vb
  572. {0x08, 0x0b},
  573. {0xfe, 0x01},
  574. {0x25, 0x01},
  575. {0x26, 0x32}, //step
  576. {0x27, 0x03}, //8.15fps
  577. {0x28, 0x96},
  578. {0x29, 0x03}, //8.15fps
  579. {0x2a, 0x96},
  580. {0x2b, 0x03}, //8.15fps
  581. {0x2c, 0x96},
  582. {0x2d, 0x04}, //8.15fps
  583. {0x2e, 0x62},
  584. {0x3c, 0x00},
  585. {0xfe, 0x00},
  586. /////////dark sun//////
  587. {0xfe, 0x00},
  588. {0x18, 0x22},
  589. {0xfe, 0x02},
  590. {0x40, 0xbf},
  591. {0x46, 0xcf},
  592. {0xfe, 0x00},
  593. {0xfe, 0x00},
  594. {0xf7, 0x1d},
  595. {0xf8, 0x84},
  596. {0xfa, 0x10},
  597. {0x05, 0x01}, //hb
  598. {0x06, 0x18},
  599. {0x07, 0x00}, //Vb
  600. {0x08, 0x2e},
  601. {0xfe, 0x01},
  602. {0x25, 0x00},
  603. {0x26, 0xa2}, //step
  604. {0x27, 0x01},
  605. {0x28, 0xe6},
  606. {0x29, 0x01},
  607. {0x2a, 0xe6},
  608. {0x2b, 0x01},
  609. {0x2c, 0xe6},
  610. {0x2d, 0x04}, // AEC_exp_level4[12:8]
  611. {0x2e, 0x62}, // AEC_exp_level4[7:0]
  612. {0x3c, 0x00},
  613. {0xfe, 0x00},
  614. {0x09, 0x01}, //row start
  615. {0x0a, 0xd0}, //
  616. {0x0b, 0x02}, //col start
  617. {0x0c, 0x70},
  618. {0x0d, 0x01}, //height
  619. {0x0e, 0x00},
  620. {0x0f, 0x01}, //width
  621. {0x10, 0x50},
  622. {0x90, 0x01}, //crop
  623. {0x91, 0x00},
  624. {0x92, 0x00},
  625. {0x93, 0x00},
  626. {0x94, 0x00},
  627. {0x95, 0x00},
  628. {0x96, 0xf0},
  629. {0x97, 0x01},
  630. {0x98, 0x40},
  631. {REGLIST_TAIL, 0x00},
  632. };