0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011 #include "et8ek8_reg.h"
0012
0013
0014
0015
0016
0017
0018 static struct et8ek8_reglist mode1_poweron_mode2_16vga_2592x1968_12_07fps = {
0019
0020
0021
0022
0023
0024
0025
0026
0027
0028
0029
0030
0031
0032 .type = ET8EK8_REGLIST_POWERON,
0033 .mode = {
0034 .sensor_width = 2592,
0035 .sensor_height = 1968,
0036 .sensor_window_origin_x = 0,
0037 .sensor_window_origin_y = 0,
0038 .sensor_window_width = 2592,
0039 .sensor_window_height = 1968,
0040 .width = 3288,
0041 .height = 2016,
0042 .window_origin_x = 0,
0043 .window_origin_y = 0,
0044 .window_width = 2592,
0045 .window_height = 1968,
0046 .pixel_clock = 80000000,
0047 .ext_clock = 9600000,
0048 .timeperframe = {
0049 .numerator = 100,
0050 .denominator = 1207
0051 },
0052 .max_exp = 2012,
0053
0054 .bus_format = MEDIA_BUS_FMT_SGRBG10_1X10,
0055 .sensitivity = 65536
0056 },
0057 .regs = {
0058
0059 { ET8EK8_REG_8BIT, 0x126C, 0xCC },
0060
0061 { ET8EK8_REG_8BIT, 0x1269, 0x00 },
0062
0063 { ET8EK8_REG_8BIT, 0x1220, 0x89 },
0064
0065 { ET8EK8_REG_8BIT, 0x123A, 0x07 },
0066 { ET8EK8_REG_8BIT, 0x1241, 0x94 },
0067 { ET8EK8_REG_8BIT, 0x1242, 0x02 },
0068 { ET8EK8_REG_8BIT, 0x124B, 0x00 },
0069 { ET8EK8_REG_8BIT, 0x1255, 0xFF },
0070 { ET8EK8_REG_8BIT, 0x1256, 0x9F },
0071 { ET8EK8_REG_8BIT, 0x1258, 0x00 },
0072
0073 { ET8EK8_REG_8BIT, 0x125D, 0x88 },
0074
0075 { ET8EK8_REG_8BIT, 0x125E, 0xC0 },
0076
0077 { ET8EK8_REG_8BIT, 0x1263, 0x98 },
0078 { ET8EK8_REG_8BIT, 0x1268, 0xC6 },
0079 { ET8EK8_REG_8BIT, 0x1434, 0x00 },
0080 { ET8EK8_REG_8BIT, 0x1163, 0x44 },
0081 { ET8EK8_REG_8BIT, 0x1166, 0x29 },
0082 { ET8EK8_REG_8BIT, 0x1140, 0x02 },
0083 { ET8EK8_REG_8BIT, 0x1011, 0x24 },
0084 { ET8EK8_REG_8BIT, 0x1151, 0x80 },
0085 { ET8EK8_REG_8BIT, 0x1152, 0x23 },
0086
0087 { ET8EK8_REG_8BIT, 0x1014, 0x05 },
0088 { ET8EK8_REG_8BIT, 0x1033, 0x06 },
0089 { ET8EK8_REG_8BIT, 0x1034, 0x79 },
0090 { ET8EK8_REG_8BIT, 0x1423, 0x3F },
0091 { ET8EK8_REG_8BIT, 0x1424, 0x3F },
0092 { ET8EK8_REG_8BIT, 0x1426, 0x00 },
0093
0094 { ET8EK8_REG_8BIT, 0x1439, 0x00 },
0095
0096 { ET8EK8_REG_8BIT, 0x161F, 0x60 },
0097
0098 { ET8EK8_REG_8BIT, 0x1634, 0x00 },
0099 { ET8EK8_REG_8BIT, 0x1646, 0x00 },
0100 { ET8EK8_REG_8BIT, 0x1648, 0x00 },
0101 { ET8EK8_REG_8BIT, 0x113E, 0x01 },
0102 { ET8EK8_REG_8BIT, 0x113F, 0x22 },
0103 { ET8EK8_REG_8BIT, 0x1239, 0x64 },
0104 { ET8EK8_REG_8BIT, 0x1238, 0x02 },
0105 { ET8EK8_REG_8BIT, 0x123B, 0x70 },
0106 { ET8EK8_REG_8BIT, 0x123A, 0x07 },
0107 { ET8EK8_REG_8BIT, 0x121B, 0x64 },
0108 { ET8EK8_REG_8BIT, 0x121D, 0x64 },
0109 { ET8EK8_REG_8BIT, 0x1221, 0x00 },
0110 { ET8EK8_REG_8BIT, 0x1220, 0x89 },
0111 { ET8EK8_REG_8BIT, 0x1223, 0x00 },
0112 { ET8EK8_REG_8BIT, 0x1222, 0x54 },
0113 { ET8EK8_REG_8BIT, 0x125D, 0x88 },
0114 { ET8EK8_REG_TERM, 0, 0}
0115 }
0116 };
0117
0118
0119 static struct et8ek8_reglist mode1_16vga_2592x1968_13_12fps_dpcm10_8 = {
0120
0121
0122
0123
0124
0125
0126
0127
0128
0129
0130
0131
0132
0133 .type = ET8EK8_REGLIST_MODE,
0134 .mode = {
0135 .sensor_width = 2592,
0136 .sensor_height = 1968,
0137 .sensor_window_origin_x = 0,
0138 .sensor_window_origin_y = 0,
0139 .sensor_window_width = 2592,
0140 .sensor_window_height = 1968,
0141 .width = 3072,
0142 .height = 2016,
0143 .window_origin_x = 0,
0144 .window_origin_y = 0,
0145 .window_width = 2592,
0146 .window_height = 1968,
0147 .pixel_clock = 80000000,
0148 .ext_clock = 9600000,
0149 .timeperframe = {
0150 .numerator = 100,
0151 .denominator = 1292
0152 },
0153 .max_exp = 2012,
0154
0155 .bus_format = MEDIA_BUS_FMT_SGRBG10_DPCM8_1X8,
0156 .sensitivity = 65536
0157 },
0158 .regs = {
0159 { ET8EK8_REG_8BIT, 0x1239, 0x57 },
0160 { ET8EK8_REG_8BIT, 0x1238, 0x82 },
0161 { ET8EK8_REG_8BIT, 0x123B, 0x70 },
0162 { ET8EK8_REG_8BIT, 0x123A, 0x06 },
0163 { ET8EK8_REG_8BIT, 0x121B, 0x64 },
0164 { ET8EK8_REG_8BIT, 0x121D, 0x64 },
0165 { ET8EK8_REG_8BIT, 0x1221, 0x00 },
0166 { ET8EK8_REG_8BIT, 0x1220, 0x80 },
0167 { ET8EK8_REG_8BIT, 0x1223, 0x00 },
0168 { ET8EK8_REG_8BIT, 0x1222, 0x54 },
0169 { ET8EK8_REG_8BIT, 0x125D, 0x83 },
0170 { ET8EK8_REG_TERM, 0, 0}
0171 }
0172 };
0173
0174
0175 static struct et8ek8_reglist mode3_4vga_1296x984_29_99fps_dpcm10_8 = {
0176
0177
0178
0179
0180
0181
0182
0183
0184
0185
0186
0187
0188
0189 .type = ET8EK8_REGLIST_MODE,
0190 .mode = {
0191 .sensor_width = 2592,
0192 .sensor_height = 1968,
0193 .sensor_window_origin_x = 0,
0194 .sensor_window_origin_y = 0,
0195 .sensor_window_width = 2592,
0196 .sensor_window_height = 1968,
0197 .width = 3192,
0198 .height = 1008,
0199 .window_origin_x = 0,
0200 .window_origin_y = 0,
0201 .window_width = 1296,
0202 .window_height = 984,
0203 .pixel_clock = 96533333,
0204 .ext_clock = 9600000,
0205 .timeperframe = {
0206 .numerator = 100,
0207 .denominator = 3000
0208 },
0209 .max_exp = 1004,
0210
0211 .bus_format = MEDIA_BUS_FMT_SGRBG10_DPCM8_1X8,
0212 .sensitivity = 65536
0213 },
0214 .regs = {
0215 { ET8EK8_REG_8BIT, 0x1239, 0x5A },
0216 { ET8EK8_REG_8BIT, 0x1238, 0x82 },
0217 { ET8EK8_REG_8BIT, 0x123B, 0x70 },
0218 { ET8EK8_REG_8BIT, 0x123A, 0x05 },
0219 { ET8EK8_REG_8BIT, 0x121B, 0x63 },
0220 { ET8EK8_REG_8BIT, 0x1220, 0x85 },
0221 { ET8EK8_REG_8BIT, 0x1221, 0x00 },
0222 { ET8EK8_REG_8BIT, 0x1222, 0x54 },
0223 { ET8EK8_REG_8BIT, 0x1223, 0x00 },
0224 { ET8EK8_REG_8BIT, 0x121D, 0x63 },
0225 { ET8EK8_REG_8BIT, 0x125D, 0x83 },
0226 { ET8EK8_REG_TERM, 0, 0}
0227 }
0228 };
0229
0230
0231 static struct et8ek8_reglist mode4_svga_864x656_29_88fps = {
0232
0233
0234
0235
0236
0237
0238
0239
0240
0241
0242
0243
0244
0245 .type = ET8EK8_REGLIST_MODE,
0246 .mode = {
0247 .sensor_width = 2592,
0248 .sensor_height = 1968,
0249 .sensor_window_origin_x = 0,
0250 .sensor_window_origin_y = 0,
0251 .sensor_window_width = 2592,
0252 .sensor_window_height = 1968,
0253 .width = 3984,
0254 .height = 672,
0255 .window_origin_x = 0,
0256 .window_origin_y = 0,
0257 .window_width = 864,
0258 .window_height = 656,
0259 .pixel_clock = 80000000,
0260 .ext_clock = 9600000,
0261 .timeperframe = {
0262 .numerator = 100,
0263 .denominator = 2988
0264 },
0265 .max_exp = 668,
0266
0267 .bus_format = MEDIA_BUS_FMT_SGRBG10_1X10,
0268 .sensitivity = 65536
0269 },
0270 .regs = {
0271 { ET8EK8_REG_8BIT, 0x1239, 0x64 },
0272 { ET8EK8_REG_8BIT, 0x1238, 0x02 },
0273 { ET8EK8_REG_8BIT, 0x123B, 0x71 },
0274 { ET8EK8_REG_8BIT, 0x123A, 0x07 },
0275 { ET8EK8_REG_8BIT, 0x121B, 0x62 },
0276 { ET8EK8_REG_8BIT, 0x121D, 0x62 },
0277 { ET8EK8_REG_8BIT, 0x1221, 0x00 },
0278 { ET8EK8_REG_8BIT, 0x1220, 0xA6 },
0279 { ET8EK8_REG_8BIT, 0x1223, 0x00 },
0280 { ET8EK8_REG_8BIT, 0x1222, 0x54 },
0281 { ET8EK8_REG_8BIT, 0x125D, 0x88 },
0282 { ET8EK8_REG_TERM, 0, 0}
0283 }
0284 };
0285
0286
0287 static struct et8ek8_reglist mode5_vga_648x492_29_93fps = {
0288
0289
0290
0291
0292
0293
0294
0295
0296
0297
0298
0299
0300
0301 .type = ET8EK8_REGLIST_MODE,
0302 .mode = {
0303 .sensor_width = 2592,
0304 .sensor_height = 1968,
0305 .sensor_window_origin_x = 0,
0306 .sensor_window_origin_y = 0,
0307 .sensor_window_width = 2592,
0308 .sensor_window_height = 1968,
0309 .width = 5304,
0310 .height = 504,
0311 .window_origin_x = 0,
0312 .window_origin_y = 0,
0313 .window_width = 648,
0314 .window_height = 492,
0315 .pixel_clock = 80000000,
0316 .ext_clock = 9600000,
0317 .timeperframe = {
0318 .numerator = 100,
0319 .denominator = 2993
0320 },
0321 .max_exp = 500,
0322
0323 .bus_format = MEDIA_BUS_FMT_SGRBG10_1X10,
0324 .sensitivity = 65536
0325 },
0326 .regs = {
0327 { ET8EK8_REG_8BIT, 0x1239, 0x64 },
0328 { ET8EK8_REG_8BIT, 0x1238, 0x02 },
0329 { ET8EK8_REG_8BIT, 0x123B, 0x71 },
0330 { ET8EK8_REG_8BIT, 0x123A, 0x07 },
0331 { ET8EK8_REG_8BIT, 0x121B, 0x61 },
0332 { ET8EK8_REG_8BIT, 0x121D, 0x61 },
0333 { ET8EK8_REG_8BIT, 0x1221, 0x00 },
0334 { ET8EK8_REG_8BIT, 0x1220, 0xDD },
0335 { ET8EK8_REG_8BIT, 0x1223, 0x00 },
0336 { ET8EK8_REG_8BIT, 0x1222, 0x54 },
0337 { ET8EK8_REG_8BIT, 0x125D, 0x88 },
0338 { ET8EK8_REG_TERM, 0, 0}
0339 }
0340 };
0341
0342
0343 static struct et8ek8_reglist mode2_16vga_2592x1968_3_99fps = {
0344
0345
0346
0347
0348
0349
0350
0351
0352
0353
0354
0355
0356
0357 .type = ET8EK8_REGLIST_MODE,
0358 .mode = {
0359 .sensor_width = 2592,
0360 .sensor_height = 1968,
0361 .sensor_window_origin_x = 0,
0362 .sensor_window_origin_y = 0,
0363 .sensor_window_width = 2592,
0364 .sensor_window_height = 1968,
0365 .width = 3288,
0366 .height = 6096,
0367 .window_origin_x = 0,
0368 .window_origin_y = 0,
0369 .window_width = 2592,
0370 .window_height = 1968,
0371 .pixel_clock = 80000000,
0372 .ext_clock = 9600000,
0373 .timeperframe = {
0374 .numerator = 100,
0375 .denominator = 399
0376 },
0377 .max_exp = 6092,
0378
0379 .bus_format = MEDIA_BUS_FMT_SGRBG10_1X10,
0380 .sensitivity = 65536
0381 },
0382 .regs = {
0383 { ET8EK8_REG_8BIT, 0x1239, 0x64 },
0384 { ET8EK8_REG_8BIT, 0x1238, 0x02 },
0385 { ET8EK8_REG_8BIT, 0x123B, 0x70 },
0386 { ET8EK8_REG_8BIT, 0x123A, 0x07 },
0387 { ET8EK8_REG_8BIT, 0x121B, 0x64 },
0388 { ET8EK8_REG_8BIT, 0x121D, 0x64 },
0389 { ET8EK8_REG_8BIT, 0x1221, 0x00 },
0390 { ET8EK8_REG_8BIT, 0x1220, 0x89 },
0391 { ET8EK8_REG_8BIT, 0x1223, 0x00 },
0392 { ET8EK8_REG_8BIT, 0x1222, 0xFE },
0393 { ET8EK8_REG_TERM, 0, 0}
0394 }
0395 };
0396
0397
0398 static struct et8ek8_reglist mode_648x492_5fps = {
0399
0400
0401
0402
0403
0404
0405
0406
0407
0408
0409
0410
0411
0412 .type = ET8EK8_REGLIST_MODE,
0413 .mode = {
0414 .sensor_width = 2592,
0415 .sensor_height = 1968,
0416 .sensor_window_origin_x = 0,
0417 .sensor_window_origin_y = 0,
0418 .sensor_window_width = 2592,
0419 .sensor_window_height = 1968,
0420 .width = 5304,
0421 .height = 504,
0422 .window_origin_x = 0,
0423 .window_origin_y = 0,
0424 .window_width = 648,
0425 .window_height = 492,
0426 .pixel_clock = 13333333,
0427 .ext_clock = 9600000,
0428 .timeperframe = {
0429 .numerator = 100,
0430 .denominator = 499
0431 },
0432 .max_exp = 500,
0433
0434 .bus_format = MEDIA_BUS_FMT_SGRBG10_1X10,
0435 .sensitivity = 65536
0436 },
0437 .regs = {
0438 { ET8EK8_REG_8BIT, 0x1239, 0x64 },
0439 { ET8EK8_REG_8BIT, 0x1238, 0x02 },
0440 { ET8EK8_REG_8BIT, 0x123B, 0x71 },
0441 { ET8EK8_REG_8BIT, 0x123A, 0x57 },
0442 { ET8EK8_REG_8BIT, 0x121B, 0x61 },
0443 { ET8EK8_REG_8BIT, 0x121D, 0x61 },
0444 { ET8EK8_REG_8BIT, 0x1221, 0x00 },
0445 { ET8EK8_REG_8BIT, 0x1220, 0xDD },
0446 { ET8EK8_REG_8BIT, 0x1223, 0x00 },
0447 { ET8EK8_REG_8BIT, 0x1222, 0x54 },
0448 { ET8EK8_REG_8BIT, 0x125D, 0x88 },
0449 { ET8EK8_REG_TERM, 0, 0}
0450 }
0451 };
0452
0453
0454 static struct et8ek8_reglist mode3_4vga_1296x984_5fps = {
0455
0456
0457
0458
0459
0460
0461
0462
0463
0464
0465
0466
0467
0468 .type = ET8EK8_REGLIST_MODE,
0469 .mode = {
0470 .sensor_width = 2592,
0471 .sensor_height = 1968,
0472 .sensor_window_origin_x = 0,
0473 .sensor_window_origin_y = 0,
0474 .sensor_window_width = 2592,
0475 .sensor_window_height = 1968,
0476 .width = 3288,
0477 .height = 3000,
0478 .window_origin_x = 0,
0479 .window_origin_y = 0,
0480 .window_width = 1296,
0481 .window_height = 984,
0482 .pixel_clock = 49400000,
0483 .ext_clock = 9600000,
0484 .timeperframe = {
0485 .numerator = 100,
0486 .denominator = 501
0487 },
0488 .max_exp = 2996,
0489
0490 .bus_format = MEDIA_BUS_FMT_SGRBG10_1X10,
0491 .sensitivity = 65536
0492 },
0493 .regs = {
0494 { ET8EK8_REG_8BIT, 0x1239, 0x7B },
0495 { ET8EK8_REG_8BIT, 0x1238, 0x82 },
0496 { ET8EK8_REG_8BIT, 0x123B, 0x70 },
0497 { ET8EK8_REG_8BIT, 0x123A, 0x17 },
0498 { ET8EK8_REG_8BIT, 0x121B, 0x63 },
0499 { ET8EK8_REG_8BIT, 0x121D, 0x63 },
0500 { ET8EK8_REG_8BIT, 0x1221, 0x00 },
0501 { ET8EK8_REG_8BIT, 0x1220, 0x89 },
0502 { ET8EK8_REG_8BIT, 0x1223, 0x00 },
0503 { ET8EK8_REG_8BIT, 0x1222, 0xFA },
0504 { ET8EK8_REG_8BIT, 0x125D, 0x88 },
0505 { ET8EK8_REG_TERM, 0, 0}
0506 }
0507 };
0508
0509
0510 static struct et8ek8_reglist mode_4vga_1296x984_25fps_dpcm10_8 = {
0511
0512
0513
0514
0515
0516
0517
0518
0519
0520
0521
0522
0523
0524 .type = ET8EK8_REGLIST_MODE,
0525 .mode = {
0526 .sensor_width = 2592,
0527 .sensor_height = 1968,
0528 .sensor_window_origin_x = 0,
0529 .sensor_window_origin_y = 0,
0530 .sensor_window_width = 2592,
0531 .sensor_window_height = 1968,
0532 .width = 3192,
0533 .height = 1056,
0534 .window_origin_x = 0,
0535 .window_origin_y = 0,
0536 .window_width = 1296,
0537 .window_height = 984,
0538 .pixel_clock = 84266667,
0539 .ext_clock = 9600000,
0540 .timeperframe = {
0541 .numerator = 100,
0542 .denominator = 2500
0543 },
0544 .max_exp = 1052,
0545
0546 .bus_format = MEDIA_BUS_FMT_SGRBG10_DPCM8_1X8,
0547 .sensitivity = 65536
0548 },
0549 .regs = {
0550 { ET8EK8_REG_8BIT, 0x1239, 0x4F },
0551 { ET8EK8_REG_8BIT, 0x1238, 0x02 },
0552 { ET8EK8_REG_8BIT, 0x123B, 0x70 },
0553 { ET8EK8_REG_8BIT, 0x123A, 0x05 },
0554 { ET8EK8_REG_8BIT, 0x121B, 0x63 },
0555 { ET8EK8_REG_8BIT, 0x1220, 0x85 },
0556 { ET8EK8_REG_8BIT, 0x1221, 0x00 },
0557 { ET8EK8_REG_8BIT, 0x1222, 0x58 },
0558 { ET8EK8_REG_8BIT, 0x1223, 0x00 },
0559 { ET8EK8_REG_8BIT, 0x121D, 0x63 },
0560 { ET8EK8_REG_8BIT, 0x125D, 0x83 },
0561 { ET8EK8_REG_TERM, 0, 0}
0562 }
0563 };
0564
0565 struct et8ek8_meta_reglist meta_reglist = {
0566 .version = "V14 03-June-2008",
0567 .reglist = {
0568 { .ptr = &mode1_poweron_mode2_16vga_2592x1968_12_07fps },
0569 { .ptr = &mode1_16vga_2592x1968_13_12fps_dpcm10_8 },
0570 { .ptr = &mode3_4vga_1296x984_29_99fps_dpcm10_8 },
0571 { .ptr = &mode4_svga_864x656_29_88fps },
0572 { .ptr = &mode5_vga_648x492_29_93fps },
0573 { .ptr = &mode2_16vga_2592x1968_3_99fps },
0574 { .ptr = &mode_648x492_5fps },
0575 { .ptr = &mode3_4vga_1296x984_5fps },
0576 { .ptr = &mode_4vga_1296x984_25fps_dpcm10_8 },
0577 { .ptr = NULL }
0578 }
0579 };