diff options
Diffstat (limited to 'linux/drivers/media/video/gspca/zc3xx.c')
-rw-r--r-- | linux/drivers/media/video/gspca/zc3xx.c | 8482 |
1 files changed, 4255 insertions, 4227 deletions
diff --git a/linux/drivers/media/video/gspca/zc3xx.c b/linux/drivers/media/video/gspca/zc3xx.c index b0599532f..f7f8c61b3 100644 --- a/linux/drivers/media/video/gspca/zc3xx.c +++ b/linux/drivers/media/video/gspca/zc3xx.c @@ -24,9 +24,6 @@ #include "gspca.h" -#define DRIVER_VERSION_NUMBER KERNEL_VERSION(2, 1, 5) -static const char version[] = "2.1.5"; - MODULE_AUTHOR("Michel Xhaard <mxhaard@users.sourceforge.net>, " "Serge A. Suchkov <Serge.A.S@tochka.ru>"); MODULE_DESCRIPTION("GSPCA ZC03xx/VC3xx USB Camera Driver"); @@ -35,6 +32,7 @@ MODULE_LICENSE("GPL"); static int force_sensor = -1; #include "jpeg.h" +#include "zc3xx-reg.h" /* specific webcam descriptor */ struct sd { @@ -48,7 +46,7 @@ struct sd { __u8 sharpness; char qindex; - char sensor; /* Type of image sensor chip */ + signed char sensor; /* Type of image sensor chip */ /* !! values used in different tables */ #define SENSOR_CS2102 0 #define SENSOR_CS2102K 1 @@ -209,30 +207,30 @@ struct usb_action { static const struct usb_action cs2102_Initial[] = { {0xa1, 0x01, 0x0008}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x01, 0x0000}, - {0xa0, 0x10, 0x0002}, - {0xa0, 0x00, 0x0010}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x20, 0x0080}, - {0xa0, 0x21, 0x0081}, - {0xa0, 0x30, 0x0083}, - {0xa0, 0x31, 0x0084}, - {0xa0, 0x32, 0x0085}, - {0xa0, 0x23, 0x0086}, - {0xa0, 0x24, 0x0087}, - {0xa0, 0x25, 0x0088}, - {0xa0, 0xb3, 0x008b}, - {0xa0, 0x03, 0x0008}, /* 00 */ - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x00, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x20, ZC3XX_R080_HBLANKHIGH}, + {0xa0, 0x21, ZC3XX_R081_HBLANKLOW}, + {0xa0, 0x30, ZC3XX_R083_RGAINADDR}, + {0xa0, 0x31, ZC3XX_R084_GGAINADDR}, + {0xa0, 0x32, ZC3XX_R085_BGAINADDR}, + {0xa0, 0x23, ZC3XX_R086_EXPTIMEHIGH}, + {0xa0, 0x24, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x25, ZC3XX_R088_EXPTIMELOW}, + {0xa0, 0xb3, ZC3XX_R08B_I2CDEVICEADDR}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00 */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, {0xaa, 0x02, 0x0008}, {0xaa, 0x03, 0x0000}, {0xaa, 0x11, 0x0000}, @@ -245,124 +243,124 @@ static const struct usb_action cs2102_Initial[] = { {0xaa, 0x30, 0x0030}, {0xaa, 0x31, 0x0030}, {0xaa, 0x32, 0x0030}, - {0xa0, 0x37, 0x0101}, - {0xa0, 0x00, 0x0019}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, + {0xa0, 0x37, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, {0xa0, 0x10, 0x01ae}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, - {0xa0, 0x68, 0x018d}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, + {0xa0, 0x68, ZC3XX_R18D_YTARGET}, {0xa0, 0x00, 0x01ad}, {0xa1, 0x01, 0x0002}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* 00 */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00 */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - {0xa0, 0x24, 0x0120}, /* gamma 5 */ - {0xa0, 0x44, 0x0121}, - {0xa0, 0x64, 0x0122}, - {0xa0, 0x84, 0x0123}, - {0xa0, 0x9d, 0x0124}, - {0xa0, 0xb2, 0x0125}, - {0xa0, 0xc4, 0x0126}, - {0xa0, 0xd3, 0x0127}, - {0xa0, 0xe0, 0x0128}, - {0xa0, 0xeb, 0x0129}, - {0xa0, 0xf4, 0x012a}, - {0xa0, 0xfb, 0x012b}, - {0xa0, 0xff, 0x012c}, - {0xa0, 0xff, 0x012d}, - {0xa0, 0xff, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x18, 0x0130}, - {0xa0, 0x20, 0x0131}, - {0xa0, 0x20, 0x0132}, - {0xa0, 0x1c, 0x0133}, - {0xa0, 0x16, 0x0134}, - {0xa0, 0x13, 0x0135}, - {0xa0, 0x10, 0x0136}, - {0xa0, 0x0e, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x06, 0x013b}, - {0xa0, 0x00, 0x013c}, - {0xa0, 0x00, 0x013d}, - {0xa0, 0x00, 0x013e}, - {0xa0, 0x01, 0x013f}, - {0xa0, 0x58, 0x010a}, /* matrix */ - {0xa0, 0xf4, 0x010b}, - {0xa0, 0xf4, 0x010c}, - {0xa0, 0xf4, 0x010d}, - {0xa0, 0x58, 0x010e}, - {0xa0, 0xf4, 0x010f}, - {0xa0, 0xf4, 0x0110}, - {0xa0, 0xf4, 0x0111}, - {0xa0, 0x58, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x24, ZC3XX_R120_GAMMA00}, /* gamma 5 */ + {0xa0, 0x44, ZC3XX_R121_GAMMA01}, + {0xa0, 0x64, ZC3XX_R122_GAMMA02}, + {0xa0, 0x84, ZC3XX_R123_GAMMA03}, + {0xa0, 0x9d, ZC3XX_R124_GAMMA04}, + {0xa0, 0xb2, ZC3XX_R125_GAMMA05}, + {0xa0, 0xc4, ZC3XX_R126_GAMMA06}, + {0xa0, 0xd3, ZC3XX_R127_GAMMA07}, + {0xa0, 0xe0, ZC3XX_R128_GAMMA08}, + {0xa0, 0xeb, ZC3XX_R129_GAMMA09}, + {0xa0, 0xf4, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xfb, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xff, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xff, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xff, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x18, ZC3XX_R130_GAMMA10}, + {0xa0, 0x20, ZC3XX_R131_GAMMA11}, + {0xa0, 0x20, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1c, ZC3XX_R133_GAMMA13}, + {0xa0, 0x16, ZC3XX_R134_GAMMA14}, + {0xa0, 0x13, ZC3XX_R135_GAMMA15}, + {0xa0, 0x10, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0e, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x06, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x00, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x00, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x00, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x01, ZC3XX_R13F_GAMMA1F}, + {0xa0, 0x58, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf4, ZC3XX_R10B_RGB01}, + {0xa0, 0xf4, ZC3XX_R10C_RGB02}, + {0xa0, 0xf4, ZC3XX_R10D_RGB10}, + {0xa0, 0x58, ZC3XX_R10E_RGB11}, + {0xa0, 0xf4, ZC3XX_R10F_RGB12}, + {0xa0, 0xf4, ZC3XX_R110_RGB20}, + {0xa0, 0xf4, ZC3XX_R111_RGB21}, + {0xa0, 0x58, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0x23, 0x0001}, {0xaa, 0x24, 0x0055}, {0xaa, 0x25, 0x00cc}, {0xaa, 0x21, 0x003f}, - {0xa0, 0x02, 0x0190}, - {0xa0, 0xab, 0x0191}, - {0xa0, 0x98, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x30, 0x0196}, - {0xa0, 0xd4, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x10, 0x01a9}, - {0xa0, 0x24, 0x01aa}, - {0xa0, 0x39, 0x001d}, - {0xa0, 0x70, 0x001e}, - {0xa0, 0xb0, 0x001f}, - {0xa0, 0xff, 0x0020}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x02, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0xab, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0x98, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x30, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0xd4, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x39, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0x70, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xb0, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x40, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x40, 0x0118}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, {} }; static const struct usb_action cs2102_InitialScale[] = { {0xa1, 0x01, 0x0008}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x01, 0x0000}, - {0xa0, 0x00, 0x0002}, - {0xa0, 0x00, 0x0010}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x20, 0x0080}, - {0xa0, 0x21, 0x0081}, - {0xa0, 0x30, 0x0083}, - {0xa0, 0x31, 0x0084}, - {0xa0, 0x32, 0x0085}, - {0xa0, 0x23, 0x0086}, - {0xa0, 0x24, 0x0087}, - {0xa0, 0x25, 0x0088}, - {0xa0, 0xb3, 0x008b}, - {0xa0, 0x03, 0x0008}, /* 00 */ - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x00, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x20, ZC3XX_R080_HBLANKHIGH}, + {0xa0, 0x21, ZC3XX_R081_HBLANKLOW}, + {0xa0, 0x30, ZC3XX_R083_RGAINADDR}, + {0xa0, 0x31, ZC3XX_R084_GGAINADDR}, + {0xa0, 0x32, ZC3XX_R085_BGAINADDR}, + {0xa0, 0x23, ZC3XX_R086_EXPTIMEHIGH}, + {0xa0, 0x24, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x25, ZC3XX_R088_EXPTIMELOW}, + {0xa0, 0xb3, ZC3XX_R08B_I2CDEVICEADDR}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00 */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, {0xaa, 0x02, 0x0008}, {0xaa, 0x03, 0x0000}, {0xaa, 0x11, 0x0001}, @@ -375,98 +373,98 @@ static const struct usb_action cs2102_InitialScale[] = { {0xaa, 0x30, 0x0030}, {0xaa, 0x31, 0x0030}, {0xaa, 0x32, 0x0030}, - {0xa0, 0x77, 0x0101}, - {0xa0, 0x00, 0x0019}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, + {0xa0, 0x77, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, {0xa0, 0x15, 0x01ae}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, - {0xa0, 0x68, 0x018d}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, + {0xa0, 0x68, ZC3XX_R18D_YTARGET}, {0xa0, 0x00, 0x01ad}, {0xa1, 0x01, 0x0002}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* 00 */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00 */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - {0xa0, 0x24, 0x0120}, /* gamma 5 */ - {0xa0, 0x44, 0x0121}, - {0xa0, 0x64, 0x0122}, - {0xa0, 0x84, 0x0123}, - {0xa0, 0x9d, 0x0124}, - {0xa0, 0xb2, 0x0125}, - {0xa0, 0xc4, 0x0126}, - {0xa0, 0xd3, 0x0127}, - {0xa0, 0xe0, 0x0128}, - {0xa0, 0xeb, 0x0129}, - {0xa0, 0xf4, 0x012a}, - {0xa0, 0xfb, 0x012b}, - {0xa0, 0xff, 0x012c}, - {0xa0, 0xff, 0x012d}, - {0xa0, 0xff, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x18, 0x0130}, - {0xa0, 0x20, 0x0131}, - {0xa0, 0x20, 0x0132}, - {0xa0, 0x1c, 0x0133}, - {0xa0, 0x16, 0x0134}, - {0xa0, 0x13, 0x0135}, - {0xa0, 0x10, 0x0136}, - {0xa0, 0x0e, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x06, 0x013b}, - {0xa0, 0x00, 0x013c}, - {0xa0, 0x00, 0x013d}, - {0xa0, 0x00, 0x013e}, - {0xa0, 0x01, 0x013f}, - {0xa0, 0x58, 0x010a}, /* matrix */ - {0xa0, 0xf4, 0x010b}, - {0xa0, 0xf4, 0x010c}, - {0xa0, 0xf4, 0x010d}, - {0xa0, 0x58, 0x010e}, - {0xa0, 0xf4, 0x010f}, - {0xa0, 0xf4, 0x0110}, - {0xa0, 0xf4, 0x0111}, - {0xa0, 0x58, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x24, ZC3XX_R120_GAMMA00}, /* gamma 5 */ + {0xa0, 0x44, ZC3XX_R121_GAMMA01}, + {0xa0, 0x64, ZC3XX_R122_GAMMA02}, + {0xa0, 0x84, ZC3XX_R123_GAMMA03}, + {0xa0, 0x9d, ZC3XX_R124_GAMMA04}, + {0xa0, 0xb2, ZC3XX_R125_GAMMA05}, + {0xa0, 0xc4, ZC3XX_R126_GAMMA06}, + {0xa0, 0xd3, ZC3XX_R127_GAMMA07}, + {0xa0, 0xe0, ZC3XX_R128_GAMMA08}, + {0xa0, 0xeb, ZC3XX_R129_GAMMA09}, + {0xa0, 0xf4, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xfb, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xff, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xff, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xff, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x18, ZC3XX_R130_GAMMA10}, + {0xa0, 0x20, ZC3XX_R131_GAMMA11}, + {0xa0, 0x20, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1c, ZC3XX_R133_GAMMA13}, + {0xa0, 0x16, ZC3XX_R134_GAMMA14}, + {0xa0, 0x13, ZC3XX_R135_GAMMA15}, + {0xa0, 0x10, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0e, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x06, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x00, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x00, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x00, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x01, ZC3XX_R13F_GAMMA1F}, + {0xa0, 0x58, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf4, ZC3XX_R10B_RGB01}, + {0xa0, 0xf4, ZC3XX_R10C_RGB02}, + {0xa0, 0xf4, ZC3XX_R10D_RGB10}, + {0xa0, 0x58, ZC3XX_R10E_RGB11}, + {0xa0, 0xf4, ZC3XX_R10F_RGB12}, + {0xa0, 0xf4, ZC3XX_R110_RGB20}, + {0xa0, 0xf4, ZC3XX_R111_RGB21}, + {0xa0, 0x58, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0x23, 0x0000}, {0xaa, 0x24, 0x00aa}, {0xaa, 0x25, 0x00e6}, {0xaa, 0x21, 0x003f}, - {0xa0, 0x01, 0x0190}, - {0xa0, 0x55, 0x0191}, - {0xa0, 0xcc, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x18, 0x0196}, - {0xa0, 0x6a, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x10, 0x01a9}, - {0xa0, 0x24, 0x01aa}, - {0xa0, 0x3f, 0x001d}, - {0xa0, 0xa5, 0x001e}, - {0xa0, 0xf0, 0x001f}, - {0xa0, 0xff, 0x0020}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x01, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x55, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0xcc, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x18, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x6a, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x3f, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0xa5, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xf0, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x40, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x40, 0x0118}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, {} }; static const struct usb_action cs2102_50HZ[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0x0f, 0x008c}, /* 00,0f,8c,aa */ {0xaa, 0x03, 0x0005}, /* 00,03,05,aa */ {0xaa, 0x04, 0x00ac}, /* 00,04,ac,aa */ @@ -475,23 +473,23 @@ static const struct usb_action cs2102_50HZ[] = { {0xaa, 0x1b, 0x0000}, /* 00,1b,00,aa */ {0xaa, 0x1c, 0x0005}, /* 00,1c,05,aa */ {0xaa, 0x1d, 0x00ac}, /* 00,1d,ac,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x3f, 0x0191}, /* 01,91,3f,cc */ - {0xa0, 0xf0, 0x0192}, /* 01,92,f0,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x42, 0x0197}, /* 01,97,42,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc */ - {0xa0, 0x24, 0x01aa}, /* 01,aa,24,cc */ - {0xa0, 0x8c, 0x001d}, /* 00,1d,8c,cc */ - {0xa0, 0xb0, 0x001e}, /* 00,1e,b0,cc */ - {0xa0, 0xd0, 0x001f}, /* 00,1f,d0,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x3f, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,3f,cc */ + {0xa0, 0xf0, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,f0,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x42, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,42,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc */ + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,24,cc */ + {0xa0, 0x8c, ZC3XX_R01D_HSYNC_0}, /* 00,1d,8c,cc */ + {0xa0, 0xb0, ZC3XX_R01E_HSYNC_1}, /* 00,1e,b0,cc */ + {0xa0, 0xd0, ZC3XX_R01F_HSYNC_2}, /* 00,1f,d0,cc */ {} }; static const struct usb_action cs2102_50HZScale[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0x0f, 0x0093}, /* 00,0f,93,aa */ {0xaa, 0x03, 0x0005}, /* 00,03,05,aa */ {0xaa, 0x04, 0x00a1}, /* 00,04,a1,aa */ @@ -500,23 +498,23 @@ static const struct usb_action cs2102_50HZScale[] = { {0xaa, 0x1b, 0x0000}, /* 00,1b,00,aa */ {0xaa, 0x1c, 0x0005}, /* 00,1c,05,aa */ {0xaa, 0x1d, 0x00a1}, /* 00,1d,a1,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x3f, 0x0191}, /* 01,91,3f,cc */ - {0xa0, 0xf7, 0x0192}, /* 01,92,f7,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x83, 0x0197}, /* 01,97,83,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc */ - {0xa0, 0x24, 0x01aa}, /* 01,aa,24,cc */ - {0xa0, 0x93, 0x001d}, /* 00,1d,93,cc */ - {0xa0, 0xb0, 0x001e}, /* 00,1e,b0,cc */ - {0xa0, 0xd0, 0x001f}, /* 00,1f,d0,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x3f, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,3f,cc */ + {0xa0, 0xf7, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,f7,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x83, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,83,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc */ + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,24,cc */ + {0xa0, 0x93, ZC3XX_R01D_HSYNC_0}, /* 00,1d,93,cc */ + {0xa0, 0xb0, ZC3XX_R01E_HSYNC_1}, /* 00,1e,b0,cc */ + {0xa0, 0xd0, ZC3XX_R01F_HSYNC_2}, /* 00,1f,d0,cc */ {} }; static const struct usb_action cs2102_60HZ[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0x0f, 0x005d}, /* 00,0f,5d,aa */ {0xaa, 0x03, 0x0005}, /* 00,03,05,aa */ {0xaa, 0x04, 0x00aa}, /* 00,04,aa,aa */ @@ -525,23 +523,23 @@ static const struct usb_action cs2102_60HZ[] = { {0xaa, 0x1b, 0x0000}, /* 00,1b,00,aa */ {0xaa, 0x1c, 0x0005}, /* 00,1c,05,aa */ {0xaa, 0x1d, 0x00aa}, /* 00,1d,aa,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x3f, 0x0191}, /* 01,91,3f,cc */ - {0xa0, 0xe4, 0x0192}, /* 01,92,e4,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x3a, 0x0197}, /* 01,97,3a,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc */ - {0xa0, 0x24, 0x01aa}, /* 01,aa,24,cc */ - {0xa0, 0x5d, 0x001d}, /* 00,1d,5d,cc */ - {0xa0, 0x90, 0x001e}, /* 00,1e,90,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x3f, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,3f,cc */ + {0xa0, 0xe4, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,e4,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x3a, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,3a,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc */ + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,24,cc */ + {0xa0, 0x5d, ZC3XX_R01D_HSYNC_0}, /* 00,1d,5d,cc */ + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, /* 00,1e,90,cc */ {0xa0, 0xd0, 0x00c8}, /* 00,c8,d0,cc */ {} }; static const struct usb_action cs2102_60HZScale[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0x0f, 0x00b7}, /* 00,0f,b7,aa */ {0xaa, 0x03, 0x0005}, /* 00,03,05,aa */ {0xaa, 0x04, 0x00be}, /* 00,04,be,aa */ @@ -550,23 +548,23 @@ static const struct usb_action cs2102_60HZScale[] = { {0xaa, 0x1b, 0x0000}, /* 00,1b,00,aa */ {0xaa, 0x1c, 0x0005}, /* 00,1c,05,aa */ {0xaa, 0x1d, 0x00be}, /* 00,1d,be,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x3f, 0x0191}, /* 01,91,3f,cc */ - {0xa0, 0xfc, 0x0192}, /* 01,92,fc,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x69, 0x0197}, /* 01,97,69,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc */ - {0xa0, 0x24, 0x01aa}, /* 01,aa,24,cc */ - {0xa0, 0xb7, 0x001d}, /* 00,1d,b7,cc */ - {0xa0, 0xd0, 0x001e}, /* 00,1e,d0,cc */ - {0xa0, 0xe8, 0x001f}, /* 00,1f,e8,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x3f, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,3f,cc */ + {0xa0, 0xfc, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,fc,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x69, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,69,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc */ + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,24,cc */ + {0xa0, 0xb7, ZC3XX_R01D_HSYNC_0}, /* 00,1d,b7,cc */ + {0xa0, 0xd0, ZC3XX_R01E_HSYNC_1}, /* 00,1e,d0,cc */ + {0xa0, 0xe8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,e8,cc */ {} }; static const struct usb_action cs2102_NoFliker[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0x0f, 0x0059}, /* 00,0f,59,aa */ {0xaa, 0x03, 0x0005}, /* 00,03,05,aa */ {0xaa, 0x04, 0x0080}, /* 00,04,80,aa */ @@ -575,23 +573,23 @@ static const struct usb_action cs2102_NoFliker[] = { {0xaa, 0x1b, 0x0000}, /* 00,1b,00,aa */ {0xaa, 0x1c, 0x0005}, /* 00,1c,05,aa */ {0xaa, 0x1d, 0x0080}, /* 00,1d,80,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x3f, 0x0191}, /* 01,91,3f,cc */ - {0xa0, 0xf0, 0x0192}, /* 01,92,f0,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x10, 0x0197}, /* 01,97,10,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x00, 0x01a9}, /* 01,a9,00,cc */ - {0xa0, 0x00, 0x01aa}, /* 01,aa,00,cc */ - {0xa0, 0x59, 0x001d}, /* 00,1d,59,cc */ - {0xa0, 0x90, 0x001e}, /* 00,1e,90,cc */ - {0xa0, 0xc8, 0x001f}, /* 00,1f,c8,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x3f, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,3f,cc */ + {0xa0, 0xf0, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,f0,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x10, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,10,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x00, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,00,cc */ + {0xa0, 0x00, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,00,cc */ + {0xa0, 0x59, ZC3XX_R01D_HSYNC_0}, /* 00,1d,59,cc */ + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, /* 00,1e,90,cc */ + {0xa0, 0xc8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,c8,cc */ {} }; static const struct usb_action cs2102_NoFlikerScale[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0x0f, 0x0059}, /* 00,0f,59,aa */ {0xaa, 0x03, 0x0005}, /* 00,03,05,aa */ {0xaa, 0x04, 0x0080}, /* 00,04,80,aa */ @@ -600,878 +598,878 @@ static const struct usb_action cs2102_NoFlikerScale[] = { {0xaa, 0x1b, 0x0000}, /* 00,1b,00,aa */ {0xaa, 0x1c, 0x0005}, /* 00,1c,05,aa */ {0xaa, 0x1d, 0x0080}, /* 00,1d,80,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x3f, 0x0191}, /* 01,91,3f,cc */ - {0xa0, 0xf0, 0x0192}, /* 01,92,f0,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x10, 0x0197}, /* 01,97,10,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x00, 0x01a9}, /* 01,a9,00,cc */ - {0xa0, 0x00, 0x01aa}, /* 01,aa,00,cc */ - {0xa0, 0x59, 0x001d}, /* 00,1d,59,cc */ - {0xa0, 0x90, 0x001e}, /* 00,1e,90,cc */ - {0xa0, 0xc8, 0x001f}, /* 00,1f,c8,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x3f, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,3f,cc */ + {0xa0, 0xf0, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,f0,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x10, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,10,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x00, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,00,cc */ + {0xa0, 0x00, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,00,cc */ + {0xa0, 0x59, ZC3XX_R01D_HSYNC_0}, /* 00,1d,59,cc */ + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, /* 00,1e,90,cc */ + {0xa0, 0xc8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,c8,cc */ {} }; /* CS2102_KOCOM */ static const struct usb_action cs2102K_Initial[] = { - {0xa0, 0x11, 0x0002}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x08, 0x0010}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0xe8, 0x009c}, - {0xa0, 0x88, 0x009e}, - {0xa0, 0x55, 0x008b}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0a, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0b, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0c, 0x0092}, - {0xa0, 0x7c, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0d, 0x0092}, - {0xa0, 0xa3, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x03, 0x0092}, - {0xa0, 0xfb, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x05, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x06, 0x0092}, - {0xa0, 0x03, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x09, 0x0092}, - {0xa0, 0x08, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0e, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0f, 0x0092}, - {0xa0, 0x18, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x10, 0x0092}, - {0xa0, 0x18, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x11, 0x0092}, - {0xa0, 0x18, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x12, 0x0092}, - {0xa0, 0x18, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x15, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x16, 0x0092}, - {0xa0, 0x0c, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x17, 0x0092}, - {0xa0, 0x0c, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0xb7, 0x0101}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x78, 0x018d}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x20, 0x0087}, - {0xa0, 0x21, 0x0088}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, + {0xa0, 0x11, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x08, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0xe8, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, + {0xa0, 0x55, ZC3XX_R08B_I2CDEVICEADDR}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0a, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0b, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0c, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7c, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0d, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0xa3, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x03, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0xfb, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x05, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x06, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x03, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x09, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x08, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0e, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0f, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x18, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x10, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x18, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x11, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x18, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x12, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x18, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x15, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x16, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x0c, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x17, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x0c, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0xb7, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x78, ZC3XX_R18D_YTARGET}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x20, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x21, ZC3XX_R088_EXPTIMELOW}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, {0xa0, 0x00, 0x01ad}, {0xa0, 0x01, 0x01b1}, - {0xa0, 0x02, 0x0180}, - {0xa0, 0x60, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x4c, 0x0118}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - {0xa0, 0x13, 0x0120}, /* gamma 4 */ - {0xa0, 0x38, 0x0121}, - {0xa0, 0x59, 0x0122}, - {0xa0, 0x79, 0x0123}, - {0xa0, 0x92, 0x0124}, - {0xa0, 0xa7, 0x0125}, - {0xa0, 0xb9, 0x0126}, - {0xa0, 0xc8, 0x0127}, - {0xa0, 0xd4, 0x0128}, - {0xa0, 0xdf, 0x0129}, - {0xa0, 0xe7, 0x012a}, - {0xa0, 0xee, 0x012b}, - {0xa0, 0xf4, 0x012c}, - {0xa0, 0xf9, 0x012d}, - {0xa0, 0xfc, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x26, 0x0130}, - {0xa0, 0x22, 0x0131}, - {0xa0, 0x20, 0x0132}, - {0xa0, 0x1c, 0x0133}, - {0xa0, 0x16, 0x0134}, - {0xa0, 0x13, 0x0135}, - {0xa0, 0x10, 0x0136}, - {0xa0, 0x0d, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x06, 0x013b}, - {0xa0, 0x05, 0x013c}, - {0xa0, 0x04, 0x013d}, - {0xa0, 0x03, 0x013e}, - {0xa0, 0x02, 0x013f}, - {0xa0, 0x58, 0x010a}, /* matrix */ - {0xa0, 0xf4, 0x010b}, - {0xa0, 0xf4, 0x010c}, - {0xa0, 0xf4, 0x010d}, - {0xa0, 0x58, 0x010e}, - {0xa0, 0xf4, 0x010f}, - {0xa0, 0xf4, 0x0110}, - {0xa0, 0xf4, 0x0111}, - {0xa0, 0x58, 0x0112}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x13, 0x0092}, - {0xa0, 0x22, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x14, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x20, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x21, 0x0092}, - {0xa0, 0x22, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x01, 0x00a3}, - {0xa0, 0x22, 0x00a4}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x07, 0x0191}, - {0xa0, 0xee, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x3a, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x0c, 0x01a9}, - {0xa0, 0x28, 0x01aa}, - {0xa0, 0x04, 0x001d}, - {0xa0, 0x0f, 0x001e}, - {0xa0, 0x19, 0x001f}, - {0xa0, 0x1f, 0x0020}, - {0xa0, 0x60, 0x011d}, - {0xa0, 0x60, 0x011d}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x60, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x4c, 0x0118}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x20, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x21, 0x0092}, - {0xa0, 0x5c, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x13, 0x0092}, - {0xa0, 0x5c, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x14, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x20, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x21, 0x0092}, - {0xa0, 0x96, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x13, 0x0092}, - {0xa0, 0x96, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x14, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x00, 0x01a7}, + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x60, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x4c, ZC3XX_R118_BGAIN}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x13, ZC3XX_R120_GAMMA00}, /* gamma 4 */ + {0xa0, 0x38, ZC3XX_R121_GAMMA01}, + {0xa0, 0x59, ZC3XX_R122_GAMMA02}, + {0xa0, 0x79, ZC3XX_R123_GAMMA03}, + {0xa0, 0x92, ZC3XX_R124_GAMMA04}, + {0xa0, 0xa7, ZC3XX_R125_GAMMA05}, + {0xa0, 0xb9, ZC3XX_R126_GAMMA06}, + {0xa0, 0xc8, ZC3XX_R127_GAMMA07}, + {0xa0, 0xd4, ZC3XX_R128_GAMMA08}, + {0xa0, 0xdf, ZC3XX_R129_GAMMA09}, + {0xa0, 0xe7, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xee, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xf4, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xf9, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xfc, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x26, ZC3XX_R130_GAMMA10}, + {0xa0, 0x22, ZC3XX_R131_GAMMA11}, + {0xa0, 0x20, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1c, ZC3XX_R133_GAMMA13}, + {0xa0, 0x16, ZC3XX_R134_GAMMA14}, + {0xa0, 0x13, ZC3XX_R135_GAMMA15}, + {0xa0, 0x10, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0d, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x06, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x05, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x04, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x03, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x02, ZC3XX_R13F_GAMMA1F}, + {0xa0, 0x58, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf4, ZC3XX_R10B_RGB01}, + {0xa0, 0xf4, ZC3XX_R10C_RGB02}, + {0xa0, 0xf4, ZC3XX_R10D_RGB10}, + {0xa0, 0x58, ZC3XX_R10E_RGB11}, + {0xa0, 0xf4, ZC3XX_R10F_RGB12}, + {0xa0, 0xf4, ZC3XX_R110_RGB20}, + {0xa0, 0xf4, ZC3XX_R111_RGB21}, + {0xa0, 0x58, ZC3XX_R112_RGB22}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x13, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x22, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x14, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x20, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x21, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x22, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x01, ZC3XX_R0A3_EXPOSURETIMEHIGH}, + {0xa0, 0x22, ZC3XX_R0A4_EXPOSURETIMELOW}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0xee, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x3a, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x28, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x04, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0x0f, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0x19, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0x1f, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x60, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x4c, ZC3XX_R118_BGAIN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x20, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x21, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x5c, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x13, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x5c, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x14, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x20, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x21, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x96, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x13, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x96, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x14, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, {} }; static const struct usb_action cs2102K_InitialScale[] = { - {0xa0, 0x11, 0x0002}, - {0xa0, 0x00, 0x0002}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x08, 0x0010}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0xe8, 0x009c}, - {0xa0, 0x88, 0x009e}, - {0xa0, 0x55, 0x008b}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0a, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0b, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0c, 0x0092}, - {0xa0, 0x7b, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0d, 0x0092}, - {0xa0, 0xa3, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x03, 0x0092}, - {0xa0, 0xfb, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x05, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x06, 0x0092}, - {0xa0, 0x03, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x09, 0x0092}, - {0xa0, 0x08, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0e, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0f, 0x0092}, - {0xa0, 0x18, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x10, 0x0092}, - {0xa0, 0x18, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x11, 0x0092}, - {0xa0, 0x18, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x12, 0x0092}, - {0xa0, 0x18, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x15, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x16, 0x0092}, - {0xa0, 0x0c, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x17, 0x0092}, - {0xa0, 0x0c, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0xf7, 0x0101}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x78, 0x018d}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x20, 0x0087}, - {0xa0, 0x21, 0x0088}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, + {0xa0, 0x11, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x08, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0xe8, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, + {0xa0, 0x55, ZC3XX_R08B_I2CDEVICEADDR}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0a, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0b, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0c, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7b, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0d, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0xa3, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x03, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0xfb, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x05, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x06, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x03, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x09, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x08, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0e, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0f, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x18, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x10, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x18, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x11, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x18, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x12, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x18, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x15, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x16, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x0c, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x17, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x0c, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0xf7, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x78, ZC3XX_R18D_YTARGET}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x20, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x21, ZC3XX_R088_EXPTIMELOW}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, {0xa0, 0x00, 0x01ad}, {0xa0, 0x01, 0x01b1}, - {0xa0, 0x02, 0x0180}, - {0xa0, 0x60, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x4c, 0x0118}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - {0xa0, 0x13, 0x0120}, /* gamma 4 */ - {0xa0, 0x38, 0x0121}, - {0xa0, 0x59, 0x0122}, - {0xa0, 0x79, 0x0123}, - {0xa0, 0x92, 0x0124}, - {0xa0, 0xa7, 0x0125}, - {0xa0, 0xb9, 0x0126}, - {0xa0, 0xc8, 0x0127}, - {0xa0, 0xd4, 0x0128}, - {0xa0, 0xdf, 0x0129}, - {0xa0, 0xe7, 0x012a}, - {0xa0, 0xee, 0x012b}, - {0xa0, 0xf4, 0x012c}, - {0xa0, 0xf9, 0x012d}, - {0xa0, 0xfc, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x26, 0x0130}, - {0xa0, 0x22, 0x0131}, - {0xa0, 0x20, 0x0132}, - {0xa0, 0x1c, 0x0133}, - {0xa0, 0x16, 0x0134}, - {0xa0, 0x13, 0x0135}, - {0xa0, 0x10, 0x0136}, - {0xa0, 0x0d, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x06, 0x013b}, - {0xa0, 0x05, 0x013c}, - {0xa0, 0x04, 0x013d}, - {0xa0, 0x03, 0x013e}, - {0xa0, 0x02, 0x013f}, - {0xa0, 0x58, 0x010a}, /* matrix */ - {0xa0, 0xf4, 0x010b}, - {0xa0, 0xf4, 0x010c}, - {0xa0, 0xf4, 0x010d}, - {0xa0, 0x58, 0x010e}, - {0xa0, 0xf4, 0x010f}, - {0xa0, 0xf4, 0x0110}, - {0xa0, 0xf4, 0x0111}, - {0xa0, 0x58, 0x0112}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x13, 0x0092}, - {0xa0, 0x22, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x14, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x20, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x21, 0x0092}, - {0xa0, 0x22, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x01, 0x00a3}, - {0xa0, 0x22, 0x00a4}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x07, 0x0191}, - {0xa0, 0xee, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x3a, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x0c, 0x01a9}, - {0xa0, 0x28, 0x01aa}, - {0xa0, 0x04, 0x001d}, - {0xa0, 0x0f, 0x001e}, - {0xa0, 0x19, 0x001f}, - {0xa0, 0x1f, 0x0020}, - {0xa0, 0x60, 0x011d}, - {0xa0, 0x60, 0x011d}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x60, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x4c, 0x0118}, - {0xa0, 0x01, 0x0000}, - {0xa0, 0x01, 0x0000}, - {0xa0, 0x00, 0x0002}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x08, 0x0010}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0xe8, 0x009c}, - {0xa0, 0x88, 0x009e}, - {0xa0, 0x55, 0x008b}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0A, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0B, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0C, 0x0092}, - {0xa0, 0x7b, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0D, 0x0092}, - {0xa0, 0xA3, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x03, 0x0092}, - {0xa0, 0xfb, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x05, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x06, 0x0092}, - {0xa0, 0x03, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x09, 0x0092}, - {0xa0, 0x08, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0E, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x0f, 0x0092}, - {0xa0, 0x18, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x10, 0x0092}, - {0xa0, 0x18, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x11, 0x0092}, - {0xa0, 0x18, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x12, 0x0092}, - {0xa0, 0x18, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x15, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x16, 0x0092}, - {0xa0, 0x0c, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x17, 0x0092}, - {0xa0, 0x0C, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0xf7, 0x0101}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x78, 0x018d}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x20, 0x0087}, - {0xa0, 0x21, 0x0088}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x60, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x4c, ZC3XX_R118_BGAIN}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x13, ZC3XX_R120_GAMMA00}, /* gamma 4 */ + {0xa0, 0x38, ZC3XX_R121_GAMMA01}, + {0xa0, 0x59, ZC3XX_R122_GAMMA02}, + {0xa0, 0x79, ZC3XX_R123_GAMMA03}, + {0xa0, 0x92, ZC3XX_R124_GAMMA04}, + {0xa0, 0xa7, ZC3XX_R125_GAMMA05}, + {0xa0, 0xb9, ZC3XX_R126_GAMMA06}, + {0xa0, 0xc8, ZC3XX_R127_GAMMA07}, + {0xa0, 0xd4, ZC3XX_R128_GAMMA08}, + {0xa0, 0xdf, ZC3XX_R129_GAMMA09}, + {0xa0, 0xe7, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xee, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xf4, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xf9, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xfc, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x26, ZC3XX_R130_GAMMA10}, + {0xa0, 0x22, ZC3XX_R131_GAMMA11}, + {0xa0, 0x20, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1c, ZC3XX_R133_GAMMA13}, + {0xa0, 0x16, ZC3XX_R134_GAMMA14}, + {0xa0, 0x13, ZC3XX_R135_GAMMA15}, + {0xa0, 0x10, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0d, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x06, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x05, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x04, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x03, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x02, ZC3XX_R13F_GAMMA1F}, + {0xa0, 0x58, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf4, ZC3XX_R10B_RGB01}, + {0xa0, 0xf4, ZC3XX_R10C_RGB02}, + {0xa0, 0xf4, ZC3XX_R10D_RGB10}, + {0xa0, 0x58, ZC3XX_R10E_RGB11}, + {0xa0, 0xf4, ZC3XX_R10F_RGB12}, + {0xa0, 0xf4, ZC3XX_R110_RGB20}, + {0xa0, 0xf4, ZC3XX_R111_RGB21}, + {0xa0, 0x58, ZC3XX_R112_RGB22}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x13, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x22, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x14, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x20, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x21, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x22, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x01, ZC3XX_R0A3_EXPOSURETIMEHIGH}, + {0xa0, 0x22, ZC3XX_R0A4_EXPOSURETIMELOW}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0xee, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x3a, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x28, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x04, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0x0f, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0x19, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0x1f, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x60, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x4c, ZC3XX_R118_BGAIN}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x08, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0xe8, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, + {0xa0, 0x55, ZC3XX_R08B_I2CDEVICEADDR}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0A, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0B, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0C, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7b, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0D, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0xA3, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x03, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0xfb, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x05, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x06, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x03, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x09, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x08, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0E, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x0f, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x18, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x10, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x18, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x11, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x18, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x12, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x18, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x15, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x16, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x0c, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x17, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x0C, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0xf7, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x78, ZC3XX_R18D_YTARGET}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x20, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x21, ZC3XX_R088_EXPTIMELOW}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, {0xa0, 0x00, 0x01ad}, {0xa0, 0x01, 0x01b1}, - {0xa0, 0x02, 0x0180}, - {0xa0, 0x60, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x4c, 0x0118}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - {0xa0, 0x13, 0x0120}, /* gamma 4 */ - {0xa0, 0x38, 0x0121}, - {0xa0, 0x59, 0x0122}, - {0xa0, 0x79, 0x0123}, - {0xa0, 0x92, 0x0124}, - {0xa0, 0xa7, 0x0125}, - {0xa0, 0xb9, 0x0126}, - {0xa0, 0xc8, 0x0127}, - {0xa0, 0xd4, 0x0128}, - {0xa0, 0xdf, 0x0129}, - {0xa0, 0xe7, 0x012a}, - {0xa0, 0xee, 0x012b}, - {0xa0, 0xf4, 0x012c}, - {0xa0, 0xf9, 0x012d}, - {0xa0, 0xfc, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x26, 0x0130}, - {0xa0, 0x22, 0x0131}, - {0xa0, 0x20, 0x0132}, - {0xa0, 0x1c, 0x0133}, - {0xa0, 0x16, 0x0134}, - {0xa0, 0x13, 0x0135}, - {0xa0, 0x10, 0x0136}, - {0xa0, 0x0d, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x06, 0x013b}, - {0xa0, 0x05, 0x013c}, - {0xa0, 0x04, 0x013d}, - {0xa0, 0x03, 0x013e}, - {0xa0, 0x02, 0x013f}, - {0xa0, 0x58, 0x010a}, /* matrix */ - {0xa0, 0xf4, 0x010b}, - {0xa0, 0xf4, 0x010c}, - {0xa0, 0xf4, 0x010d}, - {0xa0, 0x58, 0x010e}, - {0xa0, 0xf4, 0x010f}, - {0xa0, 0xf4, 0x0110}, - {0xa0, 0xf4, 0x0111}, - {0xa0, 0x58, 0x0112}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x13, 0x0092}, - {0xa0, 0x22, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x14, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x20, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x21, 0x0092}, - {0xa0, 0x22, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x01, 0x00a3}, - {0xa0, 0x22, 0x00a4}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x07, 0x0191}, - {0xa0, 0xee, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x3a, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x0c, 0x01a9}, - {0xa0, 0x28, 0x01aa}, - {0xa0, 0x04, 0x001d}, - {0xa0, 0x0f, 0x001e}, - {0xa0, 0x19, 0x001f}, - {0xa0, 0x1f, 0x0020}, - {0xa0, 0x60, 0x011d}, - {0xa0, 0x60, 0x011d}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x60, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x4c, 0x0118}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x20, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x21, 0x0092}, - {0xa0, 0x5c, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x13, 0x0092}, - {0xa0, 0x5c, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x14, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x20, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x21, 0x0092}, - {0xa0, 0x96, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x13, 0x0092}, - {0xa0, 0x96, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x14, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x20, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x21, 0x0092}, - {0xa0, 0xd0, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x13, 0x0092}, - {0xa0, 0xd0, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x14, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x02, 0x0008}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x20, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x21, 0x0092}, - {0xa0, 0x0a, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x13, 0x0092}, - {0xa0, 0x0a, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x14, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x20, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x21, 0x0092}, - {0xa0, 0x44, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x13, 0x0092}, - {0xa0, 0x44, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x14, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x20, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x21, 0x0092}, - {0xa0, 0x7e, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x13, 0x0092}, - {0xa0, 0x7e, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x14, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x18, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x04, 0x01a7}, + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x60, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x4c, ZC3XX_R118_BGAIN}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x13, ZC3XX_R120_GAMMA00}, /* gamma 4 */ + {0xa0, 0x38, ZC3XX_R121_GAMMA01}, + {0xa0, 0x59, ZC3XX_R122_GAMMA02}, + {0xa0, 0x79, ZC3XX_R123_GAMMA03}, + {0xa0, 0x92, ZC3XX_R124_GAMMA04}, + {0xa0, 0xa7, ZC3XX_R125_GAMMA05}, + {0xa0, 0xb9, ZC3XX_R126_GAMMA06}, + {0xa0, 0xc8, ZC3XX_R127_GAMMA07}, + {0xa0, 0xd4, ZC3XX_R128_GAMMA08}, + {0xa0, 0xdf, ZC3XX_R129_GAMMA09}, + {0xa0, 0xe7, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xee, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xf4, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xf9, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xfc, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x26, ZC3XX_R130_GAMMA10}, + {0xa0, 0x22, ZC3XX_R131_GAMMA11}, + {0xa0, 0x20, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1c, ZC3XX_R133_GAMMA13}, + {0xa0, 0x16, ZC3XX_R134_GAMMA14}, + {0xa0, 0x13, ZC3XX_R135_GAMMA15}, + {0xa0, 0x10, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0d, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x06, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x05, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x04, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x03, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x02, ZC3XX_R13F_GAMMA1F}, + {0xa0, 0x58, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf4, ZC3XX_R10B_RGB01}, + {0xa0, 0xf4, ZC3XX_R10C_RGB02}, + {0xa0, 0xf4, ZC3XX_R10D_RGB10}, + {0xa0, 0x58, ZC3XX_R10E_RGB11}, + {0xa0, 0xf4, ZC3XX_R10F_RGB12}, + {0xa0, 0xf4, ZC3XX_R110_RGB20}, + {0xa0, 0xf4, ZC3XX_R111_RGB21}, + {0xa0, 0x58, ZC3XX_R112_RGB22}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x13, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x22, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x14, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x20, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x21, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x22, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x01, ZC3XX_R0A3_EXPOSURETIMEHIGH}, + {0xa0, 0x22, ZC3XX_R0A4_EXPOSURETIMELOW}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0xee, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x3a, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x28, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x04, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0x0f, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0x19, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0x1f, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x60, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x4c, ZC3XX_R118_BGAIN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x20, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x21, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x5c, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x13, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x5c, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x14, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x20, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x21, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x96, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x13, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x96, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x14, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x20, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x21, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0xd0, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x13, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0xd0, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x14, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x02, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x20, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x21, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x0a, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x13, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x0a, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x14, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x20, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x21, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x44, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x13, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x44, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x14, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x20, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x21, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7e, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x13, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7e, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x14, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x18, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, {} }; static const struct usb_action gc0305_Initial[] = { /* 640x480 */ - {0xa0, 0x01, 0x0000}, /* 00,00,01,cc */ - {0xa0, 0x03, 0x0008}, /* 00,08,03,cc */ - {0xa0, 0x01, 0x0010}, /* 00,10,01,cc */ - {0xa0, 0x04, 0x0002}, /* 00,02,04,cc */ - {0xa0, 0x02, 0x0003}, /* 00,03,02,cc */ - {0xa0, 0x80, 0x0004}, /* 00,04,80,cc */ - {0xa0, 0x01, 0x0005}, /* 00,05,01,cc */ - {0xa0, 0xe0, 0x0006}, /* 00,06,e0,cc */ - {0xa0, 0x01, 0x0001}, /* 00,01,01,cc */ - {0xa0, 0x03, 0x0012}, /* 00,12,03,cc */ - {0xa0, 0x01, 0x0012}, /* 00,12,01,cc */ - {0xa0, 0x00, 0x0098}, /* 00,98,00,cc */ - {0xa0, 0x00, 0x009a}, /* 00,9a,00,cc */ - {0xa0, 0x00, 0x011a}, /* 01,1a,00,cc */ - {0xa0, 0x00, 0x011c}, /* 01,1c,00,cc */ - {0xa0, 0xe6, 0x009c}, /* 00,9c,e6,cc */ - {0xa0, 0x86, 0x009e}, /* 00,9e,86,cc */ - {0xa0, 0x98, 0x008b}, /* 00,8b,98,cc */ + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, /* 00,00,01,cc */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00,08,03,cc */ + {0xa0, 0x01, ZC3XX_R010_CMOSSENSORSELECT}, /* 00,10,01,cc */ + {0xa0, 0x04, ZC3XX_R002_CLOCKSELECT}, /* 00,02,04,cc */ + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, /* 00,03,02,cc */ + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, /* 00,04,80,cc */ + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, /* 00,05,01,cc */ + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, /* 00,06,e0,cc */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, /* 00,01,01,cc */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,03,cc */ + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,01,cc */ + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, /* 00,98,00,cc */ + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, /* 00,9a,00,cc */ + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, /* 01,1a,00,cc */ + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, /* 01,1c,00,cc */ + {0xa0, 0xe6, ZC3XX_R09C_WINHEIGHTLOW}, /* 00,9c,e6,cc */ + {0xa0, 0x86, ZC3XX_R09E_WINWIDTHLOW}, /* 00,9e,86,cc */ + {0xa0, 0x98, ZC3XX_R08B_I2CDEVICEADDR}, /* 00,8b,98,cc */ {0xaa, 0x13, 0x0002}, /* 00,13,02,aa */ {0xaa, 0x15, 0x0003}, /* 00,15,03,aa */ {0xaa, 0x01, 0x0000}, /* 00,01,00,aa */ @@ -1481,9 +1479,9 @@ static const struct usb_action gc0305_Initial[] = { /* 640x480 */ {0xaa, 0x1d, 0x0080}, /* 00,1d,80,aa */ {0xaa, 0x1f, 0x0008}, /* 00,1f,08,aa */ {0xaa, 0x21, 0x0012}, /* 00,21,12,aa */ - {0xa0, 0x82, 0x0086}, /* 00,86,82,cc */ - {0xa0, 0x83, 0x0087}, /* 00,87,83,cc */ - {0xa0, 0x84, 0x0088}, /* 00,88,84,cc */ + {0xa0, 0x82, ZC3XX_R086_EXPTIMEHIGH}, /* 00,86,82,cc */ + {0xa0, 0x83, ZC3XX_R087_EXPTIMEMID}, /* 00,87,83,cc */ + {0xa0, 0x84, ZC3XX_R088_EXPTIMELOW}, /* 00,88,84,cc */ {0xaa, 0x05, 0x0000}, /* 00,05,00,aa */ {0xaa, 0x0a, 0x0000}, /* 00,0a,00,aa */ {0xaa, 0x0b, 0x00b0}, /* 00,0b,b0,aa */ @@ -1499,43 +1497,43 @@ static const struct usb_action gc0305_Initial[] = { /* 640x480 */ {0xaa, 0x19, 0x0086}, /* 00,19,86,aa */ {0xaa, 0x20, 0x0000}, /* 00,20,00,aa */ {0xaa, 0x1b, 0x0020}, /* 00,1b,20,aa */ - {0xa0, 0xb7, 0x0101}, /* 01,01,b7,cc */ - {0xa0, 0x05, 0x0012}, /* 00,12,05,cc */ - {0xa0, 0x0d, 0x0100}, /* 01,00,0d,cc */ - {0xa0, 0x76, 0x0189}, /* 01,89,76,cc */ + {0xa0, 0xb7, ZC3XX_R101_SENSORCORRECTION}, /* 01,01,b7,cc */ + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,05,cc */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* 01,00,0d,cc */ + {0xa0, 0x76, ZC3XX_R189_AWBSTATUS}, /* 01,89,76,cc */ {0xa0, 0x09, 0x01ad}, /* 01,ad,09,cc */ - {0xa0, 0x03, 0x01c5}, /* 01,c5,03,cc */ - {0xa0, 0x13, 0x01cb}, /* 01,cb,13,cc */ - {0xa0, 0x08, 0x0250}, /* 02,50,08,cc */ - {0xa0, 0x08, 0x0301}, /* 03,01,08,cc */ - {0xa0, 0x60, 0x01a8}, /* 01,a8,60,cc */ - {0xa0, 0x85, 0x018d}, /* 01,8d,85,cc */ + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, /* 01,c5,03,cc */ + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, /* 01,cb,13,cc */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* 02,50,08,cc */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* 03,01,08,cc */ + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, /* 01,a8,60,cc */ + {0xa0, 0x85, ZC3XX_R18D_YTARGET}, /* 01,8d,85,cc */ {0xa0, 0x00, 0x011e}, /* 01,1e,00,cc */ - {0xa0, 0x52, 0x0116}, /* 01,16,52,cc */ - {0xa0, 0x40, 0x0117}, /* 01,17,40,cc */ - {0xa0, 0x52, 0x0118}, /* 01,18,52,cc */ - {0xa0, 0x03, 0x0113}, /* 01,13,03,cc */ + {0xa0, 0x52, ZC3XX_R116_RGAIN}, /* 01,16,52,cc */ + {0xa0, 0x40, ZC3XX_R117_GGAIN}, /* 01,17,40,cc */ + {0xa0, 0x52, ZC3XX_R118_BGAIN}, /* 01,18,52,cc */ + {0xa0, 0x03, ZC3XX_R113_RGB03}, /* 01,13,03,cc */ {} }; static const struct usb_action gc0305_InitialScale[] = { /* 320x240 */ - {0xa0, 0x01, 0x0000}, /* 00,00,01,cc */ - {0xa0, 0x03, 0x0008}, /* 00,08,03,cc */ - {0xa0, 0x01, 0x0010}, /* 00,10,01,cc */ - {0xa0, 0x10, 0x0002}, /* 00,02,10,cc */ - {0xa0, 0x02, 0x0003}, /* 00,03,02,cc */ - {0xa0, 0x80, 0x0004}, /* 00,04,80,cc */ - {0xa0, 0x01, 0x0005}, /* 00,05,01,cc */ - {0xa0, 0xe0, 0x0006}, /* 00,06,e0,cc */ - {0xa0, 0x01, 0x0001}, /* 00,01,01,cc */ - {0xa0, 0x03, 0x0012}, /* 00,12,03,cc */ - {0xa0, 0x01, 0x0012}, /* 00,12,01,cc */ - {0xa0, 0x00, 0x0098}, /* 00,98,00,cc */ - {0xa0, 0x00, 0x009a}, /* 00,9a,00,cc */ - {0xa0, 0x00, 0x011a}, /* 01,1a,00,cc */ - {0xa0, 0x00, 0x011c}, /* 01,1c,00,cc */ - {0xa0, 0xe8, 0x009c}, /* 00,9c,e8,cc */ - {0xa0, 0x88, 0x009e}, /* 00,9e,88,cc */ - {0xa0, 0x98, 0x008b}, /* 00,8b,98,cc */ + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, /* 00,00,01,cc */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00,08,03,cc */ + {0xa0, 0x01, ZC3XX_R010_CMOSSENSORSELECT}, /* 00,10,01,cc */ + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, /* 00,02,10,cc */ + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, /* 00,03,02,cc */ + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, /* 00,04,80,cc */ + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, /* 00,05,01,cc */ + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, /* 00,06,e0,cc */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, /* 00,01,01,cc */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,03,cc */ + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,01,cc */ + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, /* 00,98,00,cc */ + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, /* 00,9a,00,cc */ + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, /* 01,1a,00,cc */ + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, /* 01,1c,00,cc */ + {0xa0, 0xe8, ZC3XX_R09C_WINHEIGHTLOW}, /* 00,9c,e8,cc */ + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, /* 00,9e,88,cc */ + {0xa0, 0x98, ZC3XX_R08B_I2CDEVICEADDR}, /* 00,8b,98,cc */ {0xaa, 0x13, 0x0000}, /* 00,13,00,aa */ {0xaa, 0x15, 0x0001}, /* 00,15,01,aa */ {0xaa, 0x01, 0x0000}, /* 00,01,00,aa */ @@ -1545,9 +1543,9 @@ static const struct usb_action gc0305_InitialScale[] = { /* 320x240 */ {0xaa, 0x1d, 0x0080}, /* 00,1d,80,aa */ {0xaa, 0x1f, 0x0008}, /* 00,1f,08,aa */ {0xaa, 0x21, 0x0012}, /* 00,21,12,aa */ - {0xa0, 0x82, 0x0086}, /* 00,86,82,cc */ - {0xa0, 0x83, 0x0087}, /* 00,87,83,cc */ - {0xa0, 0x84, 0x0088}, /* 00,88,84,cc */ + {0xa0, 0x82, ZC3XX_R086_EXPTIMEHIGH}, /* 00,86,82,cc */ + {0xa0, 0x83, ZC3XX_R087_EXPTIMEMID}, /* 00,87,83,cc */ + {0xa0, 0x84, ZC3XX_R088_EXPTIMELOW}, /* 00,88,84,cc */ {0xaa, 0x05, 0x0000}, /* 00,05,00,aa */ {0xaa, 0x0a, 0x0000}, /* 00,0a,00,aa */ {0xaa, 0x0b, 0x00b0}, /* 00,0b,b0,aa */ @@ -1563,115 +1561,119 @@ static const struct usb_action gc0305_InitialScale[] = { /* 320x240 */ {0xaa, 0x19, 0x0088}, /* 00,19,88,aa */ {0xaa, 0x20, 0x0000}, /* 00,20,00,aa */ {0xaa, 0x1b, 0x0020}, /* 00,1b,20,aa */ - {0xa0, 0xb7, 0x0101}, /* 01,01,b7,cc */ - {0xa0, 0x05, 0x0012}, /* 00,12,05,cc */ - {0xa0, 0x0d, 0x0100}, /* 01,00,0d,cc */ - {0xa0, 0x76, 0x0189}, /* 01,89,76,cc */ + {0xa0, 0xb7, ZC3XX_R101_SENSORCORRECTION}, /* 01,01,b7,cc */ + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,05,cc */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* 01,00,0d,cc */ + {0xa0, 0x76, ZC3XX_R189_AWBSTATUS}, /* 01,89,76,cc */ {0xa0, 0x09, 0x01ad}, /* 01,ad,09,cc */ - {0xa0, 0x03, 0x01c5}, /* 01,c5,03,cc */ - {0xa0, 0x13, 0x01cb}, /* 01,cb,13,cc */ - {0xa0, 0x08, 0x0250}, /* 02,50,08,cc */ - {0xa0, 0x08, 0x0301}, /* 03,01,08,cc */ - {0xa0, 0x60, 0x01a8}, /* 01,a8,60,cc */ + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, /* 01,c5,03,cc */ + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, /* 01,cb,13,cc */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* 02,50,08,cc */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* 03,01,08,cc */ + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, /* 01,a8,60,cc */ {0xa0, 0x00, 0x011e}, /* 01,1e,00,cc */ - {0xa0, 0x52, 0x0116}, /* 01,16,52,cc */ - {0xa0, 0x40, 0x0117}, /* 01,17,40,cc */ - {0xa0, 0x52, 0x0118}, /* 01,18,52,cc */ - {0xa0, 0x03, 0x0113}, /* 01,13,03,cc */ + {0xa0, 0x52, ZC3XX_R116_RGAIN}, /* 01,16,52,cc */ + {0xa0, 0x40, ZC3XX_R117_GGAIN}, /* 01,17,40,cc */ + {0xa0, 0x52, ZC3XX_R118_BGAIN}, /* 01,18,52,cc */ + {0xa0, 0x03, ZC3XX_R113_RGB03}, /* 01,13,03,cc */ {} }; static const struct usb_action gc0305_50HZ[] = { {0xaa, 0x82, 0x0000}, /* 00,82,00,aa */ {0xaa, 0x83, 0x0002}, /* 00,83,02,aa */ {0xaa, 0x84, 0x0038}, /* 00,84,38,aa */ /* win: 00,84,ec */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x0b, 0x0191}, /* 01,91,0b,cc */ - {0xa0, 0x18, 0x0192}, /* 01,92,18,cc */ /* win: 01,92,10 */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x8e, 0x0197}, /* 01,97,8e,cc */ /* win: 01,97,ec */ - {0xa0, 0x0e, 0x018c}, /* 01,8c,0e,cc */ - {0xa0, 0x15, 0x018f}, /* 01,8f,15,cc */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc */ - {0xa0, 0x24, 0x01aa}, /* 01,aa,24,cc */ - {0xa0, 0x62, 0x001d}, /* 00,1d,62,cc */ - {0xa0, 0x90, 0x001e}, /* 00,1e,90,cc */ - {0xa0, 0xc8, 0x001f}, /* 00,1f,c8,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ - {0xa0, 0x60, 0x011d}, /* 01,1d,60,cc */ - {0xa0, 0x42, 0x0180}, /* 01,80,42,cc */ -/* {0xa0, 0x85, 0x018d}, * 01,8d,85,cc * * if 640x480 */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x0b, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,0b,cc */ + {0xa0, 0x18, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,18,cc */ + /* win: 01,92,10 */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x8e, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,8e,cc */ + /* win: 01,97,ec */ + {0xa0, 0x0e, ZC3XX_R18C_AEFREEZE}, /* 01,8c,0e,cc */ + {0xa0, 0x15, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,15,cc */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc */ + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,24,cc */ + {0xa0, 0x62, ZC3XX_R01D_HSYNC_0}, /* 00,1d,62,cc */ + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, /* 00,1e,90,cc */ + {0xa0, 0xc8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,c8,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, /* 01,1d,60,cc */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,42,cc */ +/* {0xa0, 0x85, ZC3XX_R18D_YTARGET}, * 01,8d,85,cc * + * if 640x480 */ {} }; static const struct usb_action gc0305_60HZ[] = { {0xaa, 0x82, 0x0000}, /* 00,82,00,aa */ {0xaa, 0x83, 0x0000}, /* 00,83,00,aa */ {0xaa, 0x84, 0x00ec}, /* 00,84,ec,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x0b, 0x0191}, /* 01,91,0b,cc */ - {0xa0, 0x10, 0x0192}, /* 01,92,10,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0xec, 0x0197}, /* 01,97,ec,cc */ - {0xa0, 0x0e, 0x018c}, /* 01,8c,0e,cc */ - {0xa0, 0x15, 0x018f}, /* 01,8f,15,cc */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc */ - {0xa0, 0x24, 0x01aa}, /* 01,aa,24,cc */ - {0xa0, 0x62, 0x001d}, /* 00,1d,62,cc */ - {0xa0, 0x90, 0x001e}, /* 00,1e,90,cc */ - {0xa0, 0xc8, 0x001f}, /* 00,1f,c8,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ - {0xa0, 0x60, 0x011d}, /* 01,1d,60,cc */ - {0xa0, 0x42, 0x0180}, /* 01,80,42,cc */ - {0xa0, 0x80, 0x018d}, /* 01,8d,80,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x0b, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,0b,cc */ + {0xa0, 0x10, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,10,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0xec, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,ec,cc */ + {0xa0, 0x0e, ZC3XX_R18C_AEFREEZE}, /* 01,8c,0e,cc */ + {0xa0, 0x15, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,15,cc */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc */ + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,24,cc */ + {0xa0, 0x62, ZC3XX_R01D_HSYNC_0}, /* 00,1d,62,cc */ + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, /* 00,1e,90,cc */ + {0xa0, 0xc8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,c8,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, /* 01,1d,60,cc */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,42,cc */ + {0xa0, 0x80, ZC3XX_R18D_YTARGET}, /* 01,8d,80,cc */ {} }; static const struct usb_action gc0305_NoFliker[] = { - {0xa0, 0x0c, 0x0100}, /* 01,00,0c,cc */ + {0xa0, 0x0c, ZC3XX_R100_OPERATIONMODE}, /* 01,00,0c,cc */ {0xaa, 0x82, 0x0000}, /* 00,82,00,aa */ {0xaa, 0x83, 0x0000}, /* 00,83,00,aa */ {0xaa, 0x84, 0x0020}, /* 00,84,20,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x00, 0x0191}, /* 01,91,00,cc */ - {0xa0, 0x48, 0x0192}, /* 01,92,48,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x10, 0x0197}, /* 01,97,10,cc */ - {0xa0, 0x0e, 0x018c}, /* 01,8c,0e,cc */ - {0xa0, 0x15, 0x018f}, /* 01,8f,15,cc */ - {0xa0, 0x62, 0x001d}, /* 00,1d,62,cc */ - {0xa0, 0x90, 0x001e}, /* 00,1e,90,cc */ - {0xa0, 0xc8, 0x001f}, /* 00,1f,c8,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ - {0xa0, 0x60, 0x011d}, /* 01,1d,60,cc */ - {0xa0, 0x03, 0x0180}, /* 01,80,03,cc */ - {0xa0, 0x80, 0x018d}, /* 01,8d,80,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x00, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,00,cc */ + {0xa0, 0x48, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,48,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x10, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,10,cc */ + {0xa0, 0x0e, ZC3XX_R18C_AEFREEZE}, /* 01,8c,0e,cc */ + {0xa0, 0x15, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,15,cc */ + {0xa0, 0x62, ZC3XX_R01D_HSYNC_0}, /* 00,1d,62,cc */ + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, /* 00,1e,90,cc */ + {0xa0, 0xc8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,c8,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, /* 01,1d,60,cc */ + {0xa0, 0x03, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,03,cc */ + {0xa0, 0x80, ZC3XX_R18D_YTARGET}, /* 01,8d,80,cc */ {} }; /* play poker with registers at your own risk !! */ static const struct usb_action hdcs2020xx_Initial[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x0e, 0x0010}, - {0xa0, 0x10, 0x0002}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xd0, 0x0006}, /* D0 ?? E0 did not start */ - {0xa0, 0x01, 0x0001}, - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x08, 0x008d}, - {0xa0, 0x08, 0x0098}, - {0xa0, 0x02, 0x009a}, - {0xa0, 0x08, 0x011a}, - {0xa0, 0x02, 0x011c}, - {0xa0, 0x01, 0x009b}, - {0xa0, 0xd8, 0x009c}, - {0xa0, 0x02, 0x009d}, - {0xa0, 0x88, 0x009e}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x0e, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xd0, ZC3XX_R006_FRAMEHEIGHTLOW}, + /* D0 ?? E0 did not start */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x08, ZC3XX_R08D_COMPABILITYMODE}, + {0xa0, 0x08, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x02, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x08, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x02, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0x01, ZC3XX_R09B_WINHEIGHTHIGH}, + {0xa0, 0xd8, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x02, ZC3XX_R09D_WINWIDTHHIGH}, + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, {0xaa, 0x02, 0x0002}, {0xaa, 0x07, 0x0006}, {0xaa, 0x08, 0x0002}, @@ -1684,71 +1686,71 @@ static const struct usb_action hdcs2020xx_Initial[] = { {0xaa, 0x12, 0x0005}, {0xaa, 0x13, 0x0063}, {0xaa, 0x15, 0x0070}, - {0xa0, 0x37, 0x0101}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, + {0xa0, 0x37, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, {0xa0, 0x00, 0x01ad}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, - {0xa0, 0x70, 0x018d}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, + {0xa0, 0x70, ZC3XX_R18D_YTARGET}, {0xa1, 0x01, 0x0002}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x04, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x04, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x07, 0x01cb}, /* sharpness- */ - {0xa0, 0x11, 0x0120}, /* gamma ~4 */ - {0xa0, 0x37, 0x0121}, - {0xa0, 0x58, 0x0122}, - {0xa0, 0x79, 0x0123}, - {0xa0, 0x91, 0x0124}, - {0xa0, 0xa6, 0x0125}, - {0xa0, 0xb8, 0x0126}, - {0xa0, 0xc7, 0x0127}, - {0xa0, 0xd3, 0x0128}, - {0xa0, 0xde, 0x0129}, - {0xa0, 0xe6, 0x012a}, - {0xa0, 0xed, 0x012b}, - {0xa0, 0xf3, 0x012c}, - {0xa0, 0xf8, 0x012d}, - {0xa0, 0xfb, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x26, 0x0130}, - {0xa0, 0x23, 0x0131}, - {0xa0, 0x20, 0x0132}, - {0xa0, 0x1c, 0x0133}, - {0xa0, 0x16, 0x0134}, - {0xa0, 0x13, 0x0135}, - {0xa0, 0x10, 0x0136}, - {0xa0, 0x0d, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x06, 0x013b}, - {0xa0, 0x05, 0x013c}, - {0xa0, 0x04, 0x013d}, - {0xa0, 0x03, 0x013e}, - {0xa0, 0x02, 0x013f}, - - {0xa0, 0x4c, 0x010a}, /* matrix */ - {0xa0, 0xf5, 0x010b}, - {0xa0, 0xff, 0x010c}, - {0xa0, 0xf9, 0x010d}, - {0xa0, 0x51, 0x010e}, - {0xa0, 0xf5, 0x010f}, - {0xa0, 0xfb, 0x0110}, - {0xa0, 0xed, 0x0111}, - {0xa0, 0x5f, 0x0112}, + {0xa0, 0x07, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x11, ZC3XX_R120_GAMMA00}, /* gamma ~4 */ + {0xa0, 0x37, ZC3XX_R121_GAMMA01}, + {0xa0, 0x58, ZC3XX_R122_GAMMA02}, + {0xa0, 0x79, ZC3XX_R123_GAMMA03}, + {0xa0, 0x91, ZC3XX_R124_GAMMA04}, + {0xa0, 0xa6, ZC3XX_R125_GAMMA05}, + {0xa0, 0xb8, ZC3XX_R126_GAMMA06}, + {0xa0, 0xc7, ZC3XX_R127_GAMMA07}, + {0xa0, 0xd3, ZC3XX_R128_GAMMA08}, + {0xa0, 0xde, ZC3XX_R129_GAMMA09}, + {0xa0, 0xe6, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xed, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xf3, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xf8, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xfb, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x26, ZC3XX_R130_GAMMA10}, + {0xa0, 0x23, ZC3XX_R131_GAMMA11}, + {0xa0, 0x20, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1c, ZC3XX_R133_GAMMA13}, + {0xa0, 0x16, ZC3XX_R134_GAMMA14}, + {0xa0, 0x13, ZC3XX_R135_GAMMA15}, + {0xa0, 0x10, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0d, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x06, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x05, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x04, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x03, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x02, ZC3XX_R13F_GAMMA1F}, + + {0xa0, 0x4c, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf5, ZC3XX_R10B_RGB01}, + {0xa0, 0xff, ZC3XX_R10C_RGB02}, + {0xa0, 0xf9, ZC3XX_R10D_RGB10}, + {0xa0, 0x51, ZC3XX_R10E_RGB11}, + {0xa0, 0xf5, ZC3XX_R10F_RGB12}, + {0xa0, 0xfb, ZC3XX_R110_RGB20}, + {0xa0, 0xed, ZC3XX_R111_RGB21}, + {0xa0, 0x5f, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, - {0xa0, 0x20, 0x0087}, - {0xa0, 0x21, 0x0088}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, + {0xa0, 0x20, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x21, ZC3XX_R088_EXPTIMELOW}, {0xaa, 0x20, 0x0004}, {0xaa, 0x21, 0x003d}, {0xaa, 0x03, 0x0041}, @@ -1756,67 +1758,67 @@ static const struct usb_action hdcs2020xx_Initial[] = { {0xaa, 0x05, 0x003d}, {0xaa, 0x0e, 0x0001}, {0xaa, 0x0f, 0x0000}, - {0xa0, 0x14, 0x01a9}, - {0xa0, 0x24, 0x01aa}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x04, 0x0191}, - {0xa0, 0x3d, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x9b, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x41, 0x001d}, - {0xa0, 0x6f, 0x001e}, - {0xa0, 0xad, 0x001f}, - {0xa0, 0xff, 0x0020}, - {0xa0, 0x0f, 0x0087}, - {0xa0, 0x0e, 0x0088}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x14, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0x3d, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x9b, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x41, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0x6f, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xad, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x0f, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x0e, ZC3XX_R088_EXPTIMELOW}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0195}, {0xa1, 0x01, 0x0196}, {0xa1, 0x01, 0x0197}, - {0xa0, 0x3d, 0x0192}, - {0xa0, 0x04, 0x0191}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x1d, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x85, 0x0118}, + {0xa0, 0x3d, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x1d, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x85, ZC3XX_R118_BGAIN}, {0xa1, 0x01, 0x0116}, {0xa1, 0x01, 0x0118}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x1d, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x85, 0x0118}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x1d, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x85, ZC3XX_R118_BGAIN}, {0xa1, 0x01, 0x0116}, {0xa1, 0x01, 0x0118}, -/* {0xa0, 0x02, 0x0008}, */ +/* {0xa0, 0x02, ZC3XX_R008_CLOCKSETTING}, */ {0xa0, 0x00, 0x0007}, {} }; static const struct usb_action hdcs2020xx_InitialScale[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x0e, 0x0010}, - {0xa0, 0x00, 0x0002}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x08, 0x008d}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x03, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x03, 0x011c}, - {0xa0, 0x01, 0x009b}, - {0xa0, 0xe6, 0x009c}, - {0xa0, 0x02, 0x009d}, - {0xa0, 0x86, 0x009e}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x0e, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x08, ZC3XX_R08D_COMPABILITYMODE}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x03, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x03, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0x01, ZC3XX_R09B_WINHEIGHTHIGH}, + {0xa0, 0xe6, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x02, ZC3XX_R09D_WINWIDTHHIGH}, + {0xa0, 0x86, ZC3XX_R09E_WINWIDTHLOW}, {0xaa, 0x02, 0x0002}, {0xaa, 0x07, 0x0006}, {0xaa, 0x08, 0x0002}, @@ -1829,70 +1831,70 @@ static const struct usb_action hdcs2020xx_InitialScale[] = { {0xaa, 0x12, 0x0005}, {0xaa, 0x13, 0x0063}, {0xaa, 0x15, 0x0070}, - {0xa0, 0xb7, 0x0101}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, + {0xa0, 0xb7, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, {0xa0, 0x00, 0x01ad}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, - {0xa0, 0x70, 0x018d}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, + {0xa0, 0x70, ZC3XX_R18D_YTARGET}, {0xa1, 0x01, 0x0002}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x04, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x04, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x07, 0x01cb}, /* sharpness- */ - {0xa0, 0x11, 0x0120}, /* gamma ~4*/ - {0xa0, 0x37, 0x0121}, - {0xa0, 0x58, 0x0122}, - {0xa0, 0x79, 0x0123}, - {0xa0, 0x91, 0x0124}, - {0xa0, 0xa6, 0x0125}, - {0xa0, 0xb8, 0x0126}, - {0xa0, 0xc7, 0x0127}, - {0xa0, 0xd3, 0x0128}, - {0xa0, 0xde, 0x0129}, - {0xa0, 0xe6, 0x012a}, - {0xa0, 0xed, 0x012b}, - {0xa0, 0xf3, 0x012c}, - {0xa0, 0xf8, 0x012d}, - {0xa0, 0xfb, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x26, 0x0130}, - {0xa0, 0x23, 0x0131}, - {0xa0, 0x20, 0x0132}, - {0xa0, 0x1c, 0x0133}, - {0xa0, 0x16, 0x0134}, - {0xa0, 0x13, 0x0135}, - {0xa0, 0x10, 0x0136}, - {0xa0, 0x0d, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x06, 0x013b}, - {0xa0, 0x05, 0x013c}, - {0xa0, 0x04, 0x013d}, - {0xa0, 0x03, 0x013e}, - {0xa0, 0x02, 0x013f}, - {0xa0, 0x60, 0x010a}, /* matrix */ - {0xa0, 0xff, 0x010b}, - {0xa0, 0xff, 0x010c}, - {0xa0, 0xff, 0x010d}, - {0xa0, 0x60, 0x010e}, - {0xa0, 0xff, 0x010f}, - {0xa0, 0xff, 0x0110}, - {0xa0, 0xff, 0x0111}, - {0xa0, 0x60, 0x0112}, + {0xa0, 0x07, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x11, ZC3XX_R120_GAMMA00}, /* gamma ~4*/ + {0xa0, 0x37, ZC3XX_R121_GAMMA01}, + {0xa0, 0x58, ZC3XX_R122_GAMMA02}, + {0xa0, 0x79, ZC3XX_R123_GAMMA03}, + {0xa0, 0x91, ZC3XX_R124_GAMMA04}, + {0xa0, 0xa6, ZC3XX_R125_GAMMA05}, + {0xa0, 0xb8, ZC3XX_R126_GAMMA06}, + {0xa0, 0xc7, ZC3XX_R127_GAMMA07}, + {0xa0, 0xd3, ZC3XX_R128_GAMMA08}, + {0xa0, 0xde, ZC3XX_R129_GAMMA09}, + {0xa0, 0xe6, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xed, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xf3, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xf8, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xfb, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x26, ZC3XX_R130_GAMMA10}, + {0xa0, 0x23, ZC3XX_R131_GAMMA11}, + {0xa0, 0x20, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1c, ZC3XX_R133_GAMMA13}, + {0xa0, 0x16, ZC3XX_R134_GAMMA14}, + {0xa0, 0x13, ZC3XX_R135_GAMMA15}, + {0xa0, 0x10, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0d, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x06, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x05, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x04, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x03, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x02, ZC3XX_R13F_GAMMA1F}, + {0xa0, 0x60, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xff, ZC3XX_R10B_RGB01}, + {0xa0, 0xff, ZC3XX_R10C_RGB02}, + {0xa0, 0xff, ZC3XX_R10D_RGB10}, + {0xa0, 0x60, ZC3XX_R10E_RGB11}, + {0xa0, 0xff, ZC3XX_R10F_RGB12}, + {0xa0, 0xff, ZC3XX_R110_RGB20}, + {0xa0, 0xff, ZC3XX_R111_RGB21}, + {0xa0, 0x60, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, - {0xa0, 0x20, 0x0087}, - {0xa0, 0x21, 0x0088}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, + {0xa0, 0x20, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x21, ZC3XX_R088_EXPTIMELOW}, {0xaa, 0x20, 0x0002}, {0xaa, 0x21, 0x001b}, {0xaa, 0x03, 0x0044}, @@ -1900,62 +1902,62 @@ static const struct usb_action hdcs2020xx_InitialScale[] = { {0xaa, 0x05, 0x001b}, {0xaa, 0x0e, 0x0001}, {0xaa, 0x0f, 0x0000}, - {0xa0, 0x14, 0x01a9}, - {0xa0, 0x24, 0x01aa}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x02, 0x0191}, - {0xa0, 0x1b, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x4d, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x44, 0x001d}, - {0xa0, 0x6f, 0x001e}, - {0xa0, 0xad, 0x001f}, - {0xa0, 0xeb, 0x0020}, - {0xa0, 0x0f, 0x0087}, - {0xa0, 0x0e, 0x0088}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x14, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x02, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0x1b, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x4d, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x44, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0x6f, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xad, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xeb, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x0f, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x0e, ZC3XX_R088_EXPTIMELOW}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0195}, {0xa1, 0x01, 0x0196}, {0xa1, 0x01, 0x0197}, - {0xa0, 0x1b, 0x0192}, - {0xa0, 0x02, 0x0191}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x1d, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x99, 0x0118}, + {0xa0, 0x1b, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x02, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x1d, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x99, ZC3XX_R118_BGAIN}, {0xa1, 0x01, 0x0116}, {0xa1, 0x01, 0x0118}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x1d, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x99, 0x0118}, -/* {0xa0, 0x02, 0x0008}, */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x1d, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x99, ZC3XX_R118_BGAIN}, +/* {0xa0, 0x02, ZC3XX_R008_CLOCKSETTING}, */ {0xa0, 0x00, 0x0007}, /* {0xa0, 0x18, 0x00fe}, */ {} }; static const struct usb_action hdcs2020xb_Initial[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x11, 0x0002}, - {0xa0, 0x03, 0x0008}, /* qtable 0x05 */ - {0xa0, 0x08, 0x0010}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0xe8, 0x009c}, - {0xa0, 0x88, 0x009e}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x11, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* qtable 0x05 */ + {0xa0, 0x08, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0xe8, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, {0xaa, 0x1c, 0x0000}, {0xaa, 0x0a, 0x0001}, {0xaa, 0x0b, 0x0006}, @@ -1973,121 +1975,121 @@ static const struct usb_action hdcs2020xb_Initial[] = { {0xaa, 0x15, 0x004e}, {0xaa, 0x1c, 0x0004}, - {0xa0, 0xb7, 0x0101}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x70, 0x018d}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, + {0xa0, 0xb7, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x70, ZC3XX_R18D_YTARGET}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, {0xa1, 0x01, 0x0002}, {0xa1, 0x01, 0x0008}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x02, 0x0180}, - {0xa0, 0x40, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x40, 0x0118}, + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - {0xa0, 0x13, 0x0120}, /* gamma 4 */ - {0xa0, 0x38, 0x0121}, - {0xa0, 0x59, 0x0122}, - {0xa0, 0x79, 0x0123}, - {0xa0, 0x92, 0x0124}, - {0xa0, 0xa7, 0x0125}, - {0xa0, 0xb9, 0x0126}, - {0xa0, 0xc8, 0x0127}, - {0xa0, 0xd4, 0x0128}, - {0xa0, 0xdf, 0x0129}, - {0xa0, 0xe7, 0x012a}, - {0xa0, 0xee, 0x012b}, - {0xa0, 0xf4, 0x012c}, - {0xa0, 0xf9, 0x012d}, - {0xa0, 0xfc, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x26, 0x0130}, - {0xa0, 0x22, 0x0131}, - {0xa0, 0x20, 0x0132}, - {0xa0, 0x1c, 0x0133}, - {0xa0, 0x16, 0x0134}, - {0xa0, 0x13, 0x0135}, - {0xa0, 0x10, 0x0136}, - {0xa0, 0x0d, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x06, 0x013b}, - {0xa0, 0x05, 0x013c}, - {0xa0, 0x04, 0x013d}, - {0xa0, 0x03, 0x013e}, - {0xa0, 0x02, 0x013f}, - - {0xa0, 0x66, 0x010a}, /* matrix */ - {0xa0, 0xed, 0x010b}, - {0xa0, 0xed, 0x010c}, - {0xa0, 0xed, 0x010d}, - {0xa0, 0x66, 0x010e}, - {0xa0, 0xed, 0x010f}, - {0xa0, 0xed, 0x0110}, - {0xa0, 0xed, 0x0111}, - {0xa0, 0x66, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x13, ZC3XX_R120_GAMMA00}, /* gamma 4 */ + {0xa0, 0x38, ZC3XX_R121_GAMMA01}, + {0xa0, 0x59, ZC3XX_R122_GAMMA02}, + {0xa0, 0x79, ZC3XX_R123_GAMMA03}, + {0xa0, 0x92, ZC3XX_R124_GAMMA04}, + {0xa0, 0xa7, ZC3XX_R125_GAMMA05}, + {0xa0, 0xb9, ZC3XX_R126_GAMMA06}, + {0xa0, 0xc8, ZC3XX_R127_GAMMA07}, + {0xa0, 0xd4, ZC3XX_R128_GAMMA08}, + {0xa0, 0xdf, ZC3XX_R129_GAMMA09}, + {0xa0, 0xe7, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xee, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xf4, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xf9, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xfc, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x26, ZC3XX_R130_GAMMA10}, + {0xa0, 0x22, ZC3XX_R131_GAMMA11}, + {0xa0, 0x20, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1c, ZC3XX_R133_GAMMA13}, + {0xa0, 0x16, ZC3XX_R134_GAMMA14}, + {0xa0, 0x13, ZC3XX_R135_GAMMA15}, + {0xa0, 0x10, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0d, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x06, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x05, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x04, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x03, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x02, ZC3XX_R13F_GAMMA1F}, + + {0xa0, 0x66, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xed, ZC3XX_R10B_RGB01}, + {0xa0, 0xed, ZC3XX_R10C_RGB02}, + {0xa0, 0xed, ZC3XX_R10D_RGB10}, + {0xa0, 0x66, ZC3XX_R10E_RGB11}, + {0xa0, 0xed, ZC3XX_R10F_RGB12}, + {0xa0, 0xed, ZC3XX_R110_RGB20}, + {0xa0, 0xed, ZC3XX_R111_RGB21}, + {0xa0, 0x66, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0x13, 0x0031}, {0xaa, 0x14, 0x0001}, {0xaa, 0x0e, 0x0004}, {0xaa, 0x19, 0x00cd}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x02, 0x0191}, - {0xa0, 0x62, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x3d, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - - {0xa0, 0x0c, 0x01a9}, /* 0x14 */ - {0xa0, 0x28, 0x01aa}, - {0xa0, 0x04, 0x001d}, - {0xa0, 0x18, 0x001e}, - {0xa0, 0x2c, 0x001f}, - {0xa0, 0x41, 0x0020}, - {0xa0, 0x60, 0x011d}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x02, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0x62, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x3d, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 0x14 */ + {0xa0, 0x28, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x04, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0x18, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0x2c, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0x41, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x40, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x40, 0x0118}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, {} }; static const struct usb_action hdcs2020xb_InitialScale[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x00, 0x0002}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x08, 0x0010}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0xe8, 0x009c}, - {0xa0, 0x88, 0x009e}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x08, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0xe8, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, {0xaa, 0x1c, 0x0000}, {0xaa, 0x0a, 0x0001}, {0xaa, 0x0b, 0x0006}, @@ -2103,182 +2105,182 @@ static const struct usb_action hdcs2020xb_InitialScale[] = { {0xaa, 0x12, 0x0018}, {0xaa, 0x15, 0x004e}, {0xaa, 0x1c, 0x0004}, - {0xa0, 0xf7, 0x0101}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x70, 0x018d}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, + {0xa0, 0xf7, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x70, ZC3XX_R18D_YTARGET}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, {0xa1, 0x01, 0x0002}, {0xa1, 0x01, 0x0008}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x02, 0x0180}, - {0xa0, 0x40, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x40, 0x0118}, + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - {0xa0, 0x13, 0x0120}, /* gamma 4 */ - {0xa0, 0x38, 0x0121}, - {0xa0, 0x59, 0x0122}, - {0xa0, 0x79, 0x0123}, - {0xa0, 0x92, 0x0124}, - {0xa0, 0xa7, 0x0125}, - {0xa0, 0xb9, 0x0126}, - {0xa0, 0xc8, 0x0127}, - {0xa0, 0xd4, 0x0128}, - {0xa0, 0xdf, 0x0129}, - {0xa0, 0xe7, 0x012a}, - {0xa0, 0xee, 0x012b}, - {0xa0, 0xf4, 0x012c}, - {0xa0, 0xf9, 0x012d}, - {0xa0, 0xfc, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x26, 0x0130}, - {0xa0, 0x22, 0x0131}, - {0xa0, 0x20, 0x0132}, - {0xa0, 0x1c, 0x0133}, - {0xa0, 0x16, 0x0134}, - {0xa0, 0x13, 0x0135}, - {0xa0, 0x10, 0x0136}, - {0xa0, 0x0d, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x06, 0x013b}, - {0xa0, 0x05, 0x013c}, - {0xa0, 0x04, 0x013d}, - {0xa0, 0x03, 0x013e}, - {0xa0, 0x02, 0x013f}, - {0xa0, 0x66, 0x010a}, /* matrix */ - {0xa0, 0xed, 0x010b}, - {0xa0, 0xed, 0x010c}, - {0xa0, 0xed, 0x010d}, - {0xa0, 0x66, 0x010e}, - {0xa0, 0xed, 0x010f}, - {0xa0, 0xed, 0x0110}, - {0xa0, 0xed, 0x0111}, - {0xa0, 0x66, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x13, ZC3XX_R120_GAMMA00}, /* gamma 4 */ + {0xa0, 0x38, ZC3XX_R121_GAMMA01}, + {0xa0, 0x59, ZC3XX_R122_GAMMA02}, + {0xa0, 0x79, ZC3XX_R123_GAMMA03}, + {0xa0, 0x92, ZC3XX_R124_GAMMA04}, + {0xa0, 0xa7, ZC3XX_R125_GAMMA05}, + {0xa0, 0xb9, ZC3XX_R126_GAMMA06}, + {0xa0, 0xc8, ZC3XX_R127_GAMMA07}, + {0xa0, 0xd4, ZC3XX_R128_GAMMA08}, + {0xa0, 0xdf, ZC3XX_R129_GAMMA09}, + {0xa0, 0xe7, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xee, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xf4, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xf9, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xfc, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x26, ZC3XX_R130_GAMMA10}, + {0xa0, 0x22, ZC3XX_R131_GAMMA11}, + {0xa0, 0x20, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1c, ZC3XX_R133_GAMMA13}, + {0xa0, 0x16, ZC3XX_R134_GAMMA14}, + {0xa0, 0x13, ZC3XX_R135_GAMMA15}, + {0xa0, 0x10, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0d, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x06, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x05, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x04, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x03, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x02, ZC3XX_R13F_GAMMA1F}, + {0xa0, 0x66, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xed, ZC3XX_R10B_RGB01}, + {0xa0, 0xed, ZC3XX_R10C_RGB02}, + {0xa0, 0xed, ZC3XX_R10D_RGB10}, + {0xa0, 0x66, ZC3XX_R10E_RGB11}, + {0xa0, 0xed, ZC3XX_R10F_RGB12}, + {0xa0, 0xed, ZC3XX_R110_RGB20}, + {0xa0, 0xed, ZC3XX_R111_RGB21}, + {0xa0, 0x66, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /**** set exposure ***/ {0xaa, 0x13, 0x0031}, {0xaa, 0x14, 0x0001}, {0xaa, 0x0e, 0x0004}, {0xaa, 0x19, 0x00cd}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x02, 0x0191}, - {0xa0, 0x62, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x3d, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x0c, 0x01a9}, - {0xa0, 0x28, 0x01aa}, - {0xa0, 0x04, 0x001d}, - {0xa0, 0x18, 0x001e}, - {0xa0, 0x2c, 0x001f}, - {0xa0, 0x41, 0x0020}, - {0xa0, 0x60, 0x011d}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x02, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0x62, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x3d, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x28, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x04, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0x18, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0x2c, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0x41, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x40, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x40, 0x0118}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, {} }; static const struct usb_action hdcs2020b_50HZ[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ - {0xaa, 0x13, 0x0018}, /* 00,13,18,aa */ - {0xaa, 0x14, 0x0001}, /* 00,14,01,aa */ - {0xaa, 0x0e, 0x0005}, /* 00,0e,05,aa */ - {0xaa, 0x19, 0x001f}, /* 00,19,1f,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x02, 0x0191}, /* 01,91,02,cc */ - {0xa0, 0x76, 0x0192}, /* 01,92,76,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x46, 0x0197}, /* 01,97,46,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x0c, 0x01a9}, /* 01,a9,0c,cc */ - {0xa0, 0x28, 0x01aa}, /* 01,aa,28,cc */ - {0xa0, 0x05, 0x001d}, /* 00,1d,05,cc */ - {0xa0, 0x1a, 0x001e}, /* 00,1e,1a,cc */ - {0xa0, 0x2f, 0x001f}, /* 00,1f,2f,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ + {0xaa, 0x13, 0x0018}, /* 00,13,18,aa */ + {0xaa, 0x14, 0x0001}, /* 00,14,01,aa */ + {0xaa, 0x0e, 0x0005}, /* 00,0e,05,aa */ + {0xaa, 0x19, 0x001f}, /* 00,19,1f,aa */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x02, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,02,cc */ + {0xa0, 0x76, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,76,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x46, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,46,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,0c,cc */ + {0xa0, 0x28, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,28,cc */ + {0xa0, 0x05, ZC3XX_R01D_HSYNC_0}, /* 00,1d,05,cc */ + {0xa0, 0x1a, ZC3XX_R01E_HSYNC_1}, /* 00,1e,1a,cc */ + {0xa0, 0x2f, ZC3XX_R01F_HSYNC_2}, /* 00,1f,2f,cc */ {} }; static const struct usb_action hdcs2020b_60HZ[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ - {0xaa, 0x13, 0x0031}, /* 00,13,31,aa */ - {0xaa, 0x14, 0x0001}, /* 00,14,01,aa */ - {0xaa, 0x0e, 0x0004}, /* 00,0e,04,aa */ - {0xaa, 0x19, 0x00cd}, /* 00,19,cd,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x02, 0x0191}, /* 01,91,02,cc */ - {0xa0, 0x62, 0x0192}, /* 01,92,62,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x3d, 0x0197}, /* 01,97,3d,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x0c, 0x01a9}, /* 01,a9,0c,cc */ - {0xa0, 0x28, 0x01aa}, /* 01,aa,28,cc */ - {0xa0, 0x04, 0x001d}, /* 00,1d,04,cc */ - {0xa0, 0x18, 0x001e}, /* 00,1e,18,cc */ - {0xa0, 0x2c, 0x001f}, /* 00,1f,2c,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ + {0xaa, 0x13, 0x0031}, /* 00,13,31,aa */ + {0xaa, 0x14, 0x0001}, /* 00,14,01,aa */ + {0xaa, 0x0e, 0x0004}, /* 00,0e,04,aa */ + {0xaa, 0x19, 0x00cd}, /* 00,19,cd,aa */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x02, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,02,cc */ + {0xa0, 0x62, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,62,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x3d, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,3d,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,0c,cc */ + {0xa0, 0x28, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,28,cc */ + {0xa0, 0x04, ZC3XX_R01D_HSYNC_0}, /* 00,1d,04,cc */ + {0xa0, 0x18, ZC3XX_R01E_HSYNC_1}, /* 00,1e,18,cc */ + {0xa0, 0x2c, ZC3XX_R01F_HSYNC_2}, /* 00,1f,2c,cc */ {} }; static const struct usb_action hdcs2020b_NoFliker[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ - {0xaa, 0x13, 0x0010}, /* 00,13,10,aa */ - {0xaa, 0x14, 0x0001}, /* 00,14,01,aa */ - {0xaa, 0x0e, 0x0004}, /* 00,0e,04,aa */ - {0xaa, 0x19, 0x0000}, /* 00,19,00,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x02, 0x0191}, /* 01,91,02,cc */ - {0xa0, 0x70, 0x0192}, /* 01,92,70,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x10, 0x0197}, /* 01,97,10,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x00, 0x01a9}, /* 01,a9,00,cc */ - {0xa0, 0x00, 0x01aa}, /* 01,aa,00,cc */ - {0xa0, 0x04, 0x001d}, /* 00,1d,04,cc */ - {0xa0, 0x17, 0x001e}, /* 00,1e,17,cc */ - {0xa0, 0x2a, 0x001f}, /* 00,1f,2a,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ + {0xaa, 0x13, 0x0010}, /* 00,13,10,aa */ + {0xaa, 0x14, 0x0001}, /* 00,14,01,aa */ + {0xaa, 0x0e, 0x0004}, /* 00,0e,04,aa */ + {0xaa, 0x19, 0x0000}, /* 00,19,00,aa */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x02, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,02,cc */ + {0xa0, 0x70, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,70,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x10, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,10,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x00, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,00,cc */ + {0xa0, 0x00, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,00,cc */ + {0xa0, 0x04, ZC3XX_R01D_HSYNC_0}, /* 00,1d,04,cc */ + {0xa0, 0x17, ZC3XX_R01E_HSYNC_1}, /* 00,1e,17,cc */ + {0xa0, 0x2a, ZC3XX_R01F_HSYNC_2}, /* 00,1f,2a,cc */ {} }; static const struct usb_action hv7131bxx_Initial[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x10, 0x0002}, - {0xa0, 0x00, 0x0010}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x77, 0x0101}, - {0xa0, 0x03, 0x0008}, /* 00 */ - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x00, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x77, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00 */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, {0xaa, 0x30, 0x002d}, {0xaa, 0x01, 0x0005}, {0xaa, 0x11, 0x0000}, @@ -2291,48 +2293,48 @@ static const struct usb_action hv7131bxx_Initial[] = { {0xaa, 0x32, 0x0038}, {0xaa, 0x33, 0x0038}, {0xaa, 0x5b, 0x0001}, - {0xa0, 0x00, 0x0019}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x68, 0x018d}, - {0xa0, 0x60, 0x01a8}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x68, ZC3XX_R18D_YTARGET}, + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, {0xa0, 0x00, 0x01ad}, {0xa0, 0xc0, 0x019b}, {0xa0, 0xa0, 0x019c}, - {0xa0, 0x02, 0x0188}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, + {0xa0, 0x02, ZC3XX_R188_MINGAIN}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, {0xaa, 0x02, 0x0080}, /* {0xaa, 0x02, 0x0090}; */ {0xa1, 0x01, 0x0002}, - {0xa0, 0x00, 0x0092}, - {0xa0, 0x02, 0x0090}, + {0xa0, 0x00, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R090_I2CCOMMAND}, {0xa1, 0x01, 0x0091}, {0xa1, 0x01, 0x0095}, {0xa1, 0x01, 0x0096}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - - {0xa0, 0x50, 0x010a}, /* matrix */ - {0xa0, 0xf8, 0x010b}, - {0xa0, 0xf8, 0x010c}, - {0xa0, 0xf8, 0x010d}, - {0xa0, 0x50, 0x010e}, - {0xa0, 0xf8, 0x010f}, - {0xa0, 0xf8, 0x0110}, - {0xa0, 0xf8, 0x0111}, - {0xa0, 0x50, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + + {0xa0, 0x50, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf8, ZC3XX_R10B_RGB01}, + {0xa0, 0xf8, ZC3XX_R10C_RGB02}, + {0xa0, 0xf8, ZC3XX_R10D_RGB10}, + {0xa0, 0x50, ZC3XX_R10E_RGB11}, + {0xa0, 0xf8, ZC3XX_R10F_RGB12}, + {0xa0, 0xf8, ZC3XX_R110_RGB20}, + {0xa0, 0xf8, ZC3XX_R111_RGB21}, + {0xa0, 0x50, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x10, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x10, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0x25, 0x0007}, {0xaa, 0x26, 0x00a1}, {0xaa, 0x27, 0x0020}, @@ -2341,52 +2343,52 @@ static const struct usb_action hv7131bxx_Initial[] = { {0xaa, 0x22, 0x0016}, {0xaa, 0x23, 0x0040}, - {0xa0, 0x10, 0x0190}, /* 2F */ - {0xa0, 0x04, 0x0191}, /* 4d */ - {0xa0, 0x60, 0x0192}, - {0xa0, 0x01, 0x0195}, - {0xa0, 0x86, 0x0196}, - {0xa0, 0xa0, 0x0197}, - {0xa0, 0x07, 0x018c}, - {0xa0, 0x0f, 0x018f}, - {0xa0, 0x18, 0x01a9}, - {0xa0, 0x24, 0x01aa}, - {0xa0, 0x00, 0x001d}, - {0xa0, 0xa0, 0x001e}, - {0xa0, 0x16, 0x001f}, - {0xa0, 0x40, 0x0020}, - {0xa0, 0x60, 0x011d}, + {0xa0, 0x10, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 2F */ + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, /* 4d */ + {0xa0, 0x60, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x01, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x86, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0xa0, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x07, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x0f, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x18, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x00, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0xa0, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0x16, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0x40, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, {0xa1, 0x01, 0x001d}, {0xa1, 0x01, 0x001e}, {0xa1, 0x01, 0x001f}, {0xa1, 0x01, 0x0020}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x40, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x40, 0x0118}, -/* {0xa0, 0x02, 0x0008}, */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, +/* {0xa0, 0x02, ZC3XX_R008_CLOCKSETTING}, */ {} }; static const struct usb_action hv7131bxx_InitialScale[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x00, 0x0002}, - {0xa0, 0x00, 0x0010}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x37, 0x0101}, - {0xa0, 0x03, 0x0008}, /* 00 */ - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x00, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x37, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00 */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, {0xaa, 0x30, 0x002d}, {0xaa, 0x01, 0x0005}, {0xaa, 0x11, 0x0001}, @@ -2399,47 +2401,47 @@ static const struct usb_action hv7131bxx_InitialScale[] = { {0xaa, 0x32, 0x0038}, {0xaa, 0x33, 0x0038}, {0xaa, 0x5b, 0x0001}, - {0xa0, 0x00, 0x0019}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x70, 0x018d}, - {0xa0, 0x60, 0x01a8}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x70, ZC3XX_R18D_YTARGET}, + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, {0xa0, 0x00, 0x01ad}, {0xa0, 0xc0, 0x019b}, {0xa0, 0xa0, 0x019c}, - {0xa0, 0x02, 0x0188}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, + {0xa0, 0x02, ZC3XX_R188_MINGAIN}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, {0xaa, 0x02, 0x0090}, /* {0xaa, 0x02, 0x0080}, */ {0xa1, 0x01, 0x0002}, - {0xa0, 0x00, 0x0092}, - {0xa0, 0x02, 0x0090}, + {0xa0, 0x00, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R090_I2CCOMMAND}, {0xa1, 0x01, 0x0091}, {0xa1, 0x01, 0x0095}, {0xa1, 0x01, 0x0096}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - - {0xa0, 0x50, 0x010a}, /* matrix */ - {0xa0, 0xf8, 0x010b}, - {0xa0, 0xf8, 0x010c}, - {0xa0, 0xf8, 0x010d}, - {0xa0, 0x50, 0x010e}, - {0xa0, 0xf8, 0x010f}, - {0xa0, 0xf8, 0x0110}, - {0xa0, 0xf8, 0x0111}, - {0xa0, 0x50, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + + {0xa0, 0x50, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf8, ZC3XX_R10B_RGB01}, + {0xa0, 0xf8, ZC3XX_R10C_RGB02}, + {0xa0, 0xf8, ZC3XX_R10D_RGB10}, + {0xa0, 0x50, ZC3XX_R10E_RGB11}, + {0xa0, 0xf8, ZC3XX_R10F_RGB12}, + {0xa0, 0xf8, ZC3XX_R110_RGB20}, + {0xa0, 0xf8, ZC3XX_R111_RGB21}, + {0xa0, 0x50, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x10, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x10, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0x25, 0x0007}, {0xaa, 0x26, 0x00a1}, {0xaa, 0x27, 0x0020}, @@ -2447,57 +2449,57 @@ static const struct usb_action hv7131bxx_InitialScale[] = { {0xaa, 0x21, 0x0040}, {0xaa, 0x22, 0x0013}, {0xaa, 0x23, 0x004c}, - {0xa0, 0x10, 0x0190}, /* 2f */ - {0xa0, 0x04, 0x0191}, /* 4d */ - {0xa0, 0x60, 0x0192}, /* 60 */ - {0xa0, 0x00, 0x0195}, - {0xa0, 0xc3, 0x0196}, - {0xa0, 0x50, 0x0197}, - {0xa0, 0x0c, 0x018c}, - {0xa0, 0x18, 0x018f}, - {0xa0, 0x18, 0x01a9}, - {0xa0, 0x24, 0x01aa}, - {0xa0, 0x00, 0x001d}, - {0xa0, 0x40, 0x001e}, - {0xa0, 0x13, 0x001f}, - {0xa0, 0x4c, 0x0020}, - {0xa0, 0x60, 0x011d}, + {0xa0, 0x10, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 2f */ + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, /* 4d */ + {0xa0, 0x60, ZC3XX_R192_EXPOSURELIMITLOW}, /* 60 */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0xc3, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x50, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x0c, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x18, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x18, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x00, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0x40, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0x13, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0x4c, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, {0xa1, 0x01, 0x001d}, {0xa1, 0x01, 0x001e}, {0xa1, 0x01, 0x001f}, {0xa1, 0x01, 0x0020}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x40, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x40, 0x0118}, -/* {0xa0, 0x02, 0x0008}, */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, +/* {0xa0, 0x02, ZC3XX_R008_CLOCKSETTING}, */ {} }; static const struct usb_action hv7131cxx_Initial[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x10, 0x0002}, - {0xa0, 0x01, 0x0010}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x77, 0x0101}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x07, 0x0012}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x01, 0x009b}, - {0xa0, 0xe8, 0x009c}, - {0xa0, 0x02, 0x009d}, - {0xa0, 0x88, 0x009e}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0x05, 0x0012}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x01, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x77, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x07, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x01, ZC3XX_R09B_WINHEIGHTHIGH}, + {0xa0, 0xe8, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x02, ZC3XX_R09D_WINWIDTHHIGH}, + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, {0xaa, 0x01, 0x000c}, {0xaa, 0x11, 0x0000}, {0xaa, 0x13, 0x0000}, @@ -2506,96 +2508,96 @@ static const struct usb_action hv7131cxx_Initial[] = { {0xaa, 0x16, 0x0002}, {0xaa, 0x17, 0x0088}, - {0xa0, 0x00, 0x0019}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x89, 0x018d}, - {0xa0, 0x50, 0x01a8}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x89, ZC3XX_R18D_YTARGET}, + {0xa0, 0x50, ZC3XX_R1A8_DIGITALGAIN}, {0xa0, 0x00, 0x01ad}, {0xa0, 0xc0, 0x019b}, {0xa0, 0xa0, 0x019c}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, {0xa1, 0x01, 0x0002}, - {0xa0, 0x00, 0x0092}, - {0xa0, 0x02, 0x0090}, + {0xa0, 0x00, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R090_I2CCOMMAND}, {0xa1, 0x01, 0x0091}, {0xa1, 0x01, 0x0095}, {0xa1, 0x01, 0x0096}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - - {0xa0, 0x60, 0x010a}, /* matrix */ - {0xa0, 0xf0, 0x010b}, - {0xa0, 0xf0, 0x010c}, - {0xa0, 0xf0, 0x010d}, - {0xa0, 0x60, 0x010e}, - {0xa0, 0xf0, 0x010f}, - {0xa0, 0xf0, 0x0110}, - {0xa0, 0xf0, 0x0111}, - {0xa0, 0x60, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + + {0xa0, 0x60, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf0, ZC3XX_R10B_RGB01}, + {0xa0, 0xf0, ZC3XX_R10C_RGB02}, + {0xa0, 0xf0, ZC3XX_R10D_RGB10}, + {0xa0, 0x60, ZC3XX_R10E_RGB11}, + {0xa0, 0xf0, ZC3XX_R10F_RGB12}, + {0xa0, 0xf0, ZC3XX_R110_RGB20}, + {0xa0, 0xf0, ZC3XX_R111_RGB21}, + {0xa0, 0x60, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x10, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x10, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0x25, 0x0007}, {0xaa, 0x26, 0x0053}, {0xaa, 0x27, 0x0000}, - {0xa0, 0x10, 0x0190}, /* 2f */ - {0xa0, 0x04, 0x0191}, /* 9b */ - {0xa0, 0x60, 0x0192}, /* 80 */ - {0xa0, 0x01, 0x0195}, - {0xa0, 0xd4, 0x0196}, - {0xa0, 0xc0, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x60, 0x01a8}, - {0xa0, 0x10, 0x01a9}, - {0xa0, 0x13, 0x01aa}, + {0xa0, 0x10, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 2f */ + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, /* 9b */ + {0xa0, 0x60, ZC3XX_R192_EXPOSURELIMITLOW}, /* 80 */ + {0xa0, 0x01, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0xd4, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0xc0, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x13, ZC3XX_R1AA_DIGITALGAINSTEP}, {0xa1, 0x01, 0x001d}, {0xa1, 0x01, 0x001e}, {0xa1, 0x01, 0x001f}, {0xa1, 0x01, 0x0020}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {} }; static const struct usb_action hv7131cxx_InitialScale[] = { - {0xa0, 0x01, 0x0000}, - - {0xa0, 0x00, 0x0002}, /* diff */ - {0xa0, 0x01, 0x0010}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x77, 0x0101}, - {0xa0, 0x03, 0x0008}, - - {0xa0, 0x05, 0x0012}, - {0xa0, 0x07, 0x0012}, - - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, /* 1e0 */ - - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x01, 0x009b}, - {0xa0, 0xe8, 0x009c}, - {0xa0, 0x02, 0x009d}, - {0xa0, 0x88, 0x009e}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0x05, 0x0012}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, /* diff */ + {0xa0, 0x01, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x77, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x07, ZC3XX_R012_VIDEOCONTROLFUNC}, + + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, /* 1e0 */ + + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x01, ZC3XX_R09B_WINHEIGHTHIGH}, + {0xa0, 0xe8, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x02, ZC3XX_R09D_WINWIDTHHIGH}, + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, {0xaa, 0x01, 0x000c}, {0xaa, 0x11, 0x0000}, {0xaa, 0x13, 0x0000}, @@ -2604,101 +2606,102 @@ static const struct usb_action hv7131cxx_InitialScale[] = { {0xaa, 0x16, 0x0002}, {0xaa, 0x17, 0x0088}, - {0xa0, 0x00, 0x0019}, /* 00 */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00 */ - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x89, 0x018d}, - {0xa0, 0x50, 0x01a8}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x89, ZC3XX_R18D_YTARGET}, + {0xa0, 0x50, ZC3XX_R1A8_DIGITALGAIN}, {0xa0, 0x00, 0x01ad}, {0xa0, 0xc0, 0x019b}, {0xa0, 0xa0, 0x019c}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, {0xa1, 0x01, 0x0002}, - {0xa0, 0x00, 0x0092}, /* read the i2c chips ident */ - {0xa0, 0x02, 0x0090}, + {0xa0, 0x00, ZC3XX_R092_I2CADDRESSSELECT}, + /* read the i2c chips ident */ + {0xa0, 0x02, ZC3XX_R090_I2CCOMMAND}, {0xa1, 0x01, 0x0091}, {0xa1, 0x01, 0x0095}, {0xa1, 0x01, 0x0096}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - - {0xa0, 0x60, 0x010a}, /* matrix */ - {0xa0, 0xf0, 0x010b}, - {0xa0, 0xf0, 0x010c}, - {0xa0, 0xf0, 0x010d}, - {0xa0, 0x60, 0x010e}, - {0xa0, 0xf0, 0x010f}, - {0xa0, 0xf0, 0x0110}, - {0xa0, 0xf0, 0x0111}, - {0xa0, 0x60, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + + {0xa0, 0x60, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf0, ZC3XX_R10B_RGB01}, + {0xa0, 0xf0, ZC3XX_R10C_RGB02}, + {0xa0, 0xf0, ZC3XX_R10D_RGB10}, + {0xa0, 0x60, ZC3XX_R10E_RGB11}, + {0xa0, 0xf0, ZC3XX_R10F_RGB12}, + {0xa0, 0xf0, ZC3XX_R110_RGB20}, + {0xa0, 0xf0, ZC3XX_R111_RGB21}, + {0xa0, 0x60, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x10, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x10, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0x25, 0x0007}, {0xaa, 0x26, 0x0053}, {0xaa, 0x27, 0x0000}, - {0xa0, 0x10, 0x0190}, /* 2f */ - {0xa0, 0x04, 0x0191}, /* 9b */ - {0xa0, 0x60, 0x0192}, /* 80 */ + {0xa0, 0x10, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 2f */ + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, /* 9b */ + {0xa0, 0x60, ZC3XX_R192_EXPOSURELIMITLOW}, /* 80 */ - {0xa0, 0x01, 0x0195}, - {0xa0, 0xd4, 0x0196}, - {0xa0, 0xc0, 0x0197}, + {0xa0, 0x01, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0xd4, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0xc0, ZC3XX_R197_ANTIFLICKERLOW}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x60, 0x01a8}, - {0xa0, 0x10, 0x01a9}, - {0xa0, 0x13, 0x01aa}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x13, ZC3XX_R1AA_DIGITALGAINSTEP}, {0xa1, 0x01, 0x001d}, {0xa1, 0x01, 0x001e}, {0xa1, 0x01, 0x001f}, {0xa1, 0x01, 0x0020}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {} }; static const struct usb_action icm105axx_Initial[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x10, 0x0002}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x0c, 0x0010}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0xa1, 0x008b}, - {0xa0, 0x00, 0x0097}, - {0xa0, 0x01, 0x0098}, - {0xa0, 0x00, 0x0099}, - {0xa0, 0x01, 0x009a}, - {0xa0, 0x01, 0x011a}, - {0xa0, 0x01, 0x011c}, - {0xa0, 0x01, 0x009b}, - {0xa0, 0xe8, 0x009c}, - {0xa0, 0x02, 0x009d}, - {0xa0, 0x88, 0x009e}, - {0xa0, 0x37, 0x0101}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x0c, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0xa1, ZC3XX_R08B_I2CDEVICEADDR}, + {0xa0, 0x00, ZC3XX_R097_WINYSTARTHIGH}, + {0xa0, 0x01, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R099_WINXSTARTHIGH}, + {0xa0, 0x01, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x01, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x01, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0x01, ZC3XX_R09B_WINHEIGHTHIGH}, + {0xa0, 0xe8, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x02, ZC3XX_R09D_WINWIDTHHIGH}, + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, + {0xa0, 0x37, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, {0xaa, 0x01, 0x0010}, {0xaa, 0x03, 0x0000}, {0xaa, 0x04, 0x0001}, @@ -2779,36 +2782,36 @@ static const struct usb_action icm105axx_Initial[] = { {0xaa, 0x24, 0x0080}, {0xaa, 0x26, 0x0080}, {0xaa, 0x00, 0x0084}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, {0xaa, 0xa8, 0x00c0}, {0xa1, 0x01, 0x0002}, {0xa1, 0x01, 0x0008}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x02, 0x0180}, - {0xa0, 0x40, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x40, 0x0118}, + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - {0xa0, 0x52, 0x010a}, /* matrix */ - {0xa0, 0xf7, 0x010b}, - {0xa0, 0xf7, 0x010c}, - {0xa0, 0xf7, 0x010d}, - {0xa0, 0x52, 0x010e}, - {0xa0, 0xf7, 0x010f}, - {0xa0, 0xf7, 0x0110}, - {0xa0, 0xf7, 0x0111}, - {0xa0, 0x52, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x52, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf7, ZC3XX_R10B_RGB01}, + {0xa0, 0xf7, ZC3XX_R10C_RGB02}, + {0xa0, 0xf7, ZC3XX_R10D_RGB10}, + {0xa0, 0x52, ZC3XX_R10E_RGB11}, + {0xa0, 0xf7, ZC3XX_R10F_RGB12}, + {0xa0, 0xf7, ZC3XX_R110_RGB20}, + {0xa0, 0xf7, ZC3XX_R111_RGB21}, + {0xa0, 0x52, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0x0d, 0x0003}, {0xaa, 0x0c, 0x008c}, {0xaa, 0x0e, 0x0095}, @@ -2820,62 +2823,62 @@ static const struct usb_action icm105axx_Initial[] = { {0xaa, 0x24, 0x0080}, {0xaa, 0x26, 0x0080}, {0xaa, 0x00, 0x0084}, - {0xa0, 0x02, 0x00a3}, - {0xa0, 0x94, 0x00a4}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x04, 0x0191}, - {0xa0, 0x20, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x84, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x10, 0x01a9}, - {0xa0, 0x12, 0x01aa}, - {0xa0, 0xe3, 0x001d}, - {0xa0, 0xec, 0x001e}, - {0xa0, 0xf5, 0x001f}, - {0xa0, 0xff, 0x0020}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0xc0, 0x01a8}, - {0xa0, 0xc0, 0x011d}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x02, ZC3XX_R0A3_EXPOSURETIMEHIGH}, + {0xa0, 0x94, ZC3XX_R0A4_EXPOSURETIMELOW}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0x20, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x84, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x12, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0xe3, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0xec, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xf5, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0xc0, ZC3XX_R1A8_DIGITALGAIN}, + {0xa0, 0xc0, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x40, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x40, 0x0118}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, {} }; static const struct usb_action icm105axx_InitialScale[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x00, 0x0002}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x0c, 0x0010}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0xa1, 0x008b}, - {0xa0, 0x00, 0x0097}, - {0xa0, 0x02, 0x0098}, - {0xa0, 0x00, 0x0099}, - {0xa0, 0x02, 0x009a}, - {0xa0, 0x02, 0x011a}, - {0xa0, 0x02, 0x011c}, - {0xa0, 0x01, 0x009b}, - {0xa0, 0xe6, 0x009c}, - {0xa0, 0x02, 0x009d}, - {0xa0, 0x86, 0x009e}, - {0xa0, 0x77, 0x0101}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x0c, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0xa1, ZC3XX_R08B_I2CDEVICEADDR}, + {0xa0, 0x00, ZC3XX_R097_WINYSTARTHIGH}, + {0xa0, 0x02, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R099_WINXSTARTHIGH}, + {0xa0, 0x02, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x02, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x02, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0x01, ZC3XX_R09B_WINHEIGHTHIGH}, + {0xa0, 0xe6, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x02, ZC3XX_R09D_WINWIDTHHIGH}, + {0xa0, 0x86, ZC3XX_R09E_WINWIDTHLOW}, + {0xa0, 0x77, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, {0xaa, 0x01, 0x0010}, {0xaa, 0x03, 0x0000}, {0xaa, 0x04, 0x0001}, @@ -2903,9 +2906,9 @@ static const struct usb_action icm105axx_InitialScale[] = { {0xaa, 0x06, 0x000d}, {0xaa, 0x08, 0x0000}, {0xaa, 0x03, 0x0005}, - {0xa0, 0x04, 0x0092}, - {0xa0, 0x19, 0x0093}, - {0xa0, 0x01, 0x0090}, + {0xa0, 0x04, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x19, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, {0xa1, 0x01, 0x0091}, {0xaa, 0x05, 0x0020}, {0xaa, 0x06, 0x0005}, @@ -2959,38 +2962,38 @@ static const struct usb_action icm105axx_InitialScale[] = { {0xaa, 0x24, 0x0080}, {0xaa, 0x26, 0x0080}, {0xaa, 0x00, 0x0084}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, {0xaa, 0xa8, 0x0080}, - {0xa0, 0x78, 0x018d}, + {0xa0, 0x78, ZC3XX_R18D_YTARGET}, {0xa1, 0x01, 0x0002}, {0xa1, 0x01, 0x0008}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x02, 0x0180}, - {0xa0, 0x40, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x40, 0x0118}, + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - - {0xa0, 0x52, 0x010a}, /* matrix */ - {0xa0, 0xf7, 0x010b}, - {0xa0, 0xf7, 0x010c}, - {0xa0, 0xf7, 0x010d}, - {0xa0, 0x52, 0x010e}, - {0xa0, 0xf7, 0x010f}, - {0xa0, 0xf7, 0x0110}, - {0xa0, 0xf7, 0x0111}, - {0xa0, 0x52, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + + {0xa0, 0x52, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf7, ZC3XX_R10B_RGB01}, + {0xa0, 0xf7, ZC3XX_R10C_RGB02}, + {0xa0, 0xf7, ZC3XX_R10D_RGB10}, + {0xa0, 0x52, ZC3XX_R10E_RGB11}, + {0xa0, 0xf7, ZC3XX_R10F_RGB12}, + {0xa0, 0xf7, ZC3XX_R110_RGB20}, + {0xa0, 0xf7, ZC3XX_R111_RGB21}, + {0xa0, 0x52, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0x0d, 0x0003}, {0xaa, 0x0c, 0x0020}, {0xaa, 0x0e, 0x000e}, @@ -3002,33 +3005,33 @@ static const struct usb_action icm105axx_InitialScale[] = { {0xaa, 0x24, 0x0080}, {0xaa, 0x26, 0x0080}, {0xaa, 0x00, 0x0084}, - {0xa0, 0x02, 0x00a3}, - {0xa0, 0x0d, 0x00a4}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x04, 0x0191}, - {0xa0, 0x1a, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x4b, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x10, 0x01a9}, - {0xa0, 0x12, 0x01aa}, - {0xa0, 0xc8, 0x001d}, - {0xa0, 0xd8, 0x001e}, - {0xa0, 0xea, 0x001f}, - {0xa0, 0xff, 0x0020}, - {0xa0, 0x00, 0x01a7}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x02, ZC3XX_R0A3_EXPOSURETIMEHIGH}, + {0xa0, 0x0d, ZC3XX_R0A4_EXPOSURETIMELOW}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0x1a, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x4b, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x12, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0xc8, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0xd8, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xea, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, - {0xa0, 0x40, 0x0116}, - {0xa0, 0x40, 0x0117}, - {0xa0, 0x40, 0x0118}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, {} }; static const struct usb_action icm105a_50HZ[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0x0d, 0x0003}, /* 00,0d,03,aa */ {0xaa, 0x0c, 0x0020}, /* 00,0c,20,aa */ {0xaa, 0x0e, 0x000e}, /* 00,0e,0e,aa */ @@ -3040,26 +3043,26 @@ static const struct usb_action icm105a_50HZ[] = { {0xaa, 0x24, 0x0080}, /* 00,24,80,aa */ {0xaa, 0x26, 0x0080}, /* 00,26,80,aa */ {0xaa, 0x00, 0x0084}, /* 00,00,84,aa */ - {0xa0, 0x02, 0x00a3}, /* 00,a3,02,cc */ - {0xa0, 0x0d, 0x00a4}, /* 00,a4,0d,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x04, 0x0191}, /* 01,91,04,cc */ - {0xa0, 0x1a, 0x0192}, /* 01,92,1a,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x4b, 0x0197}, /* 01,97,4b,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc */ - {0xa0, 0x12, 0x01aa}, /* 01,aa,12,cc */ - {0xa0, 0xc8, 0x001d}, /* 00,1d,c8,cc */ - {0xa0, 0xd8, 0x001e}, /* 00,1e,d8,cc */ - {0xa0, 0xea, 0x001f}, /* 00,1f,ea,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ + {0xa0, 0x02, ZC3XX_R0A3_EXPOSURETIMEHIGH}, /* 00,a3,02,cc */ + {0xa0, 0x0d, ZC3XX_R0A4_EXPOSURETIMELOW}, /* 00,a4,0d,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,04,cc */ + {0xa0, 0x1a, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,1a,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x4b, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,4b,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc */ + {0xa0, 0x12, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,12,cc */ + {0xa0, 0xc8, ZC3XX_R01D_HSYNC_0}, /* 00,1d,c8,cc */ + {0xa0, 0xd8, ZC3XX_R01E_HSYNC_1}, /* 00,1e,d8,cc */ + {0xa0, 0xea, ZC3XX_R01F_HSYNC_2}, /* 00,1f,ea,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ {} }; static const struct usb_action icm105a_50HZScale[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0x0d, 0x0003}, /* 00,0d,03,aa */ {0xaa, 0x0c, 0x008c}, /* 00,0c,8c,aa */ {0xaa, 0x0e, 0x0095}, /* 00,0e,95,aa */ @@ -3071,28 +3074,28 @@ static const struct usb_action icm105a_50HZScale[] = { {0xaa, 0x24, 0x0080}, /* 00,24,80,aa */ {0xaa, 0x26, 0x0080}, /* 00,26,80,aa */ {0xaa, 0x00, 0x0084}, /* 00,00,84,aa */ - {0xa0, 0x02, 0x00a3}, /* 00,a3,02,cc */ - {0xa0, 0x94, 0x00a4}, /* 00,a4,94,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x04, 0x0191}, /* 01,91,04,cc */ - {0xa0, 0x20, 0x0192}, /* 01,92,20,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x84, 0x0197}, /* 01,97,84,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc */ - {0xa0, 0x12, 0x01aa}, /* 01,aa,12,cc */ - {0xa0, 0xe3, 0x001d}, /* 00,1d,e3,cc */ - {0xa0, 0xec, 0x001e}, /* 00,1e,ec,cc */ - {0xa0, 0xf5, 0x001f}, /* 00,1f,f5,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ - {0xa0, 0x00, 0x01a7}, /* 01,a7,00,cc */ - {0xa0, 0xc0, 0x01a8}, /* 01,a8,c0,cc */ + {0xa0, 0x02, ZC3XX_R0A3_EXPOSURETIMEHIGH}, /* 00,a3,02,cc */ + {0xa0, 0x94, ZC3XX_R0A4_EXPOSURETIMELOW}, /* 00,a4,94,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,04,cc */ + {0xa0, 0x20, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,20,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x84, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,84,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc */ + {0xa0, 0x12, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,12,cc */ + {0xa0, 0xe3, ZC3XX_R01D_HSYNC_0}, /* 00,1d,e3,cc */ + {0xa0, 0xec, ZC3XX_R01E_HSYNC_1}, /* 00,1e,ec,cc */ + {0xa0, 0xf5, ZC3XX_R01F_HSYNC_2}, /* 00,1f,f5,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, /* 01,a7,00,cc */ + {0xa0, 0xc0, ZC3XX_R1A8_DIGITALGAIN}, /* 01,a8,c0,cc */ {} }; static const struct usb_action icm105a_60HZ[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0x0d, 0x0003}, /* 00,0d,03,aa */ {0xaa, 0x0c, 0x0004}, /* 00,0c,04,aa */ {0xaa, 0x0e, 0x000d}, /* 00,0e,0d,aa */ @@ -3104,26 +3107,26 @@ static const struct usb_action icm105a_60HZ[] = { {0xaa, 0x24, 0x0080}, /* 00,24,80,aa */ {0xaa, 0x26, 0x0080}, /* 00,26,80,aa */ {0xaa, 0x00, 0x0084}, /* 00,00,84,aa */ - {0xa0, 0x02, 0x00a3}, /* 00,a3,02,cc */ - {0xa0, 0x08, 0x00a4}, /* 00,a4,08,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x04, 0x0191}, /* 01,91,04,cc */ - {0xa0, 0x10, 0x0192}, /* 01,92,10,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x41, 0x0197}, /* 01,97,41,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc */ - {0xa0, 0x12, 0x01aa}, /* 01,aa,12,cc */ - {0xa0, 0xc1, 0x001d}, /* 00,1d,c1,cc */ - {0xa0, 0xd4, 0x001e}, /* 00,1e,d4,cc */ - {0xa0, 0xe8, 0x001f}, /* 00,1f,e8,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ + {0xa0, 0x02, ZC3XX_R0A3_EXPOSURETIMEHIGH}, /* 00,a3,02,cc */ + {0xa0, 0x08, ZC3XX_R0A4_EXPOSURETIMELOW}, /* 00,a4,08,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,04,cc */ + {0xa0, 0x10, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,10,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x41, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,41,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc */ + {0xa0, 0x12, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,12,cc */ + {0xa0, 0xc1, ZC3XX_R01D_HSYNC_0}, /* 00,1d,c1,cc */ + {0xa0, 0xd4, ZC3XX_R01E_HSYNC_1}, /* 00,1e,d4,cc */ + {0xa0, 0xe8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,e8,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ {} }; static const struct usb_action icm105a_60HZScale[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0x0d, 0x0003}, /* 00,0d,03,aa */ {0xaa, 0x0c, 0x0008}, /* 00,0c,08,aa */ {0xaa, 0x0e, 0x0086}, /* 00,0e,86,aa */ @@ -3135,28 +3138,28 @@ static const struct usb_action icm105a_60HZScale[] = { {0xaa, 0x24, 0x0080}, /* 00,24,80,aa */ {0xaa, 0x26, 0x0080}, /* 00,26,80,aa */ {0xaa, 0x00, 0x0084}, /* 00,00,84,aa */ - {0xa0, 0x02, 0x00a3}, /* 00,a3,02,cc */ - {0xa0, 0x85, 0x00a4}, /* 00,a4,85,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x04, 0x0191}, /* 01,91,04,cc */ - {0xa0, 0x08, 0x0192}, /* 01,92,08,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x81, 0x0197}, /* 01,97,81,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc */ - {0xa0, 0x12, 0x01aa}, /* 01,aa,12,cc */ - {0xa0, 0xc2, 0x001d}, /* 00,1d,c2,cc */ - {0xa0, 0xd6, 0x001e}, /* 00,1e,d6,cc */ - {0xa0, 0xea, 0x001f}, /* 00,1f,ea,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ - {0xa0, 0x00, 0x01a7}, /* 01,a7,00,cc */ - {0xa0, 0xc0, 0x01a8}, /* 01,a8,c0,cc */ + {0xa0, 0x02, ZC3XX_R0A3_EXPOSURETIMEHIGH}, /* 00,a3,02,cc */ + {0xa0, 0x85, ZC3XX_R0A4_EXPOSURETIMELOW}, /* 00,a4,85,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,04,cc */ + {0xa0, 0x08, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,08,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x81, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,81,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc */ + {0xa0, 0x12, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,12,cc */ + {0xa0, 0xc2, ZC3XX_R01D_HSYNC_0}, /* 00,1d,c2,cc */ + {0xa0, 0xd6, ZC3XX_R01E_HSYNC_1}, /* 00,1e,d6,cc */ + {0xa0, 0xea, ZC3XX_R01F_HSYNC_2}, /* 00,1f,ea,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, /* 01,a7,00,cc */ + {0xa0, 0xc0, ZC3XX_R1A8_DIGITALGAIN}, /* 01,a8,c0,cc */ {} }; static const struct usb_action icm105a_NoFliker[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0x0d, 0x0003}, /* 00,0d,03,aa */ {0xaa, 0x0c, 0x0004}, /* 00,0c,04,aa */ {0xaa, 0x0e, 0x000d}, /* 00,0e,0d,aa */ @@ -3168,26 +3171,26 @@ static const struct usb_action icm105a_NoFliker[] = { {0xaa, 0x24, 0x0080}, /* 00,24,80,aa */ {0xaa, 0x26, 0x0080}, /* 00,26,80,aa */ {0xaa, 0x00, 0x0084}, /* 00,00,84,aa */ - {0xa0, 0x02, 0x00a3}, /* 00,a3,02,cc */ - {0xa0, 0x00, 0x00a4}, /* 00,a4,00,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x04, 0x0191}, /* 01,91,04,cc */ - {0xa0, 0x20, 0x0192}, /* 01,92,20,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x10, 0x0197}, /* 01,97,10,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x00, 0x01a9}, /* 01,a9,00,cc */ - {0xa0, 0x00, 0x01aa}, /* 01,aa,00,cc */ - {0xa0, 0xc1, 0x001d}, /* 00,1d,c1,cc */ - {0xa0, 0xd4, 0x001e}, /* 00,1e,d4,cc */ - {0xa0, 0xe8, 0x001f}, /* 00,1f,e8,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ + {0xa0, 0x02, ZC3XX_R0A3_EXPOSURETIMEHIGH}, /* 00,a3,02,cc */ + {0xa0, 0x00, ZC3XX_R0A4_EXPOSURETIMELOW}, /* 00,a4,00,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,04,cc */ + {0xa0, 0x20, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,20,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x10, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,10,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x00, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,00,cc */ + {0xa0, 0x00, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,00,cc */ + {0xa0, 0xc1, ZC3XX_R01D_HSYNC_0}, /* 00,1d,c1,cc */ + {0xa0, 0xd4, ZC3XX_R01E_HSYNC_1}, /* 00,1e,d4,cc */ + {0xa0, 0xe8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,e8,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ {} }; static const struct usb_action icm105a_NoFlikerScale[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0x0d, 0x0003}, /* 00,0d,03,aa */ {0xaa, 0x0c, 0x0004}, /* 00,0c,04,aa */ {0xaa, 0x0e, 0x0081}, /* 00,0e,81,aa */ @@ -3199,52 +3202,52 @@ static const struct usb_action icm105a_NoFlikerScale[] = { {0xaa, 0x24, 0x0080}, /* 00,24,80,aa */ {0xaa, 0x26, 0x0080}, /* 00,26,80,aa */ {0xaa, 0x00, 0x0084}, /* 00,00,84,aa */ - {0xa0, 0x02, 0x00a3}, /* 00,a3,02,cc */ - {0xa0, 0x80, 0x00a4}, /* 00,a4,80,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x04, 0x0191}, /* 01,91,04,cc */ - {0xa0, 0x20, 0x0192}, /* 01,92,20,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x10, 0x0197}, /* 01,97,10,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x00, 0x01a9}, /* 01,a9,00,cc */ - {0xa0, 0x00, 0x01aa}, /* 01,aa,00,cc */ - {0xa0, 0xc1, 0x001d}, /* 00,1d,c1,cc */ - {0xa0, 0xd4, 0x001e}, /* 00,1e,d4,cc */ - {0xa0, 0xe8, 0x001f}, /* 00,1f,e8,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ - {0xa0, 0x00, 0x01a7}, /* 01,a7,00,cc */ - {0xa0, 0xc0, 0x01a8}, /* 01,a8,c0,cc */ + {0xa0, 0x02, ZC3XX_R0A3_EXPOSURETIMEHIGH}, /* 00,a3,02,cc */ + {0xa0, 0x80, ZC3XX_R0A4_EXPOSURETIMELOW}, /* 00,a4,80,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,04,cc */ + {0xa0, 0x20, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,20,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x10, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,10,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x00, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,00,cc */ + {0xa0, 0x00, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,00,cc */ + {0xa0, 0xc1, ZC3XX_R01D_HSYNC_0}, /* 00,1d,c1,cc */ + {0xa0, 0xd4, ZC3XX_R01E_HSYNC_1}, /* 00,1e,d4,cc */ + {0xa0, 0xe8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,e8,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ + {0xa0, 0x00, ZC3XX_R1A7_CALCGLOBALMEAN}, /* 01,a7,00,cc */ + {0xa0, 0xc0, ZC3XX_R1A8_DIGITALGAIN}, /* 01,a8,c0,cc */ {} }; static const struct usb_action MC501CB_InitialScale[] = { - {0xa0, 0x01, 0x0000}, /* 00,00,01,cc */ - {0xa0, 0x00, 0x0002}, /* 00,02,00,cc */ - {0xa0, 0x01, 0x0010}, /* 00,10,01,cc */ - {0xa0, 0x01, 0x0001}, /* 00,01,01,cc */ - {0xa0, 0x03, 0x0008}, /* 00,08,03,cc */ - {0xa0, 0x01, 0x0012}, /* 00,12,01,cc */ - {0xa0, 0x05, 0x0012}, /* 00,12,05,cc */ - {0xa0, 0x02, 0x0003}, /* 00,03,02,cc */ - {0xa0, 0x80, 0x0004}, /* 00,04,80,cc */ - {0xa0, 0x01, 0x0005}, /* 00,05,01,cc */ - {0xa0, 0xd8, 0x0006}, /* 00,06,d8,cc */ - {0xa0, 0x00, 0x0098}, /* 00,98,00,cc */ - {0xa0, 0x00, 0x009a}, /* 00,9a,00,cc */ - {0xa0, 0x00, 0x011a}, /* 01,1a,00,cc */ - {0xa0, 0x00, 0x011c}, /* 01,1c,00,cc */ - {0xa0, 0x01, 0x009b}, /* 00,9b,01,cc */ - {0xa0, 0xde, 0x009c}, /* 00,9c,de,cc */ - {0xa0, 0x02, 0x009d}, /* 00,9d,02,cc */ - {0xa0, 0x86, 0x009e}, /* 00,9e,86,cc */ - {0xa0, 0x33, 0x0086}, /* 00,86,33,cc */ - {0xa0, 0x34, 0x0087}, /* 00,87,34,cc */ - {0xa0, 0x35, 0x0088}, /* 00,88,35,cc */ - {0xa0, 0xb0, 0x008b}, /* 00,8b,b0,cc */ - {0xa0, 0x05, 0x0012}, /* 00,12,05,cc */ + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, /* 00,00,01,cc */ + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, /* 00,02,00,cc */ + {0xa0, 0x01, ZC3XX_R010_CMOSSENSORSELECT}, /* 00,10,01,cc */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, /* 00,01,01,cc */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00,08,03,cc */ + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,01,cc */ + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,05,cc */ + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, /* 00,03,02,cc */ + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, /* 00,04,80,cc */ + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, /* 00,05,01,cc */ + {0xa0, 0xd8, ZC3XX_R006_FRAMEHEIGHTLOW}, /* 00,06,d8,cc */ + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, /* 00,98,00,cc */ + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, /* 00,9a,00,cc */ + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, /* 01,1a,00,cc */ + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, /* 01,1c,00,cc */ + {0xa0, 0x01, ZC3XX_R09B_WINHEIGHTHIGH}, /* 00,9b,01,cc */ + {0xa0, 0xde, ZC3XX_R09C_WINHEIGHTLOW}, /* 00,9c,de,cc */ + {0xa0, 0x02, ZC3XX_R09D_WINWIDTHHIGH}, /* 00,9d,02,cc */ + {0xa0, 0x86, ZC3XX_R09E_WINWIDTHLOW}, /* 00,9e,86,cc */ + {0xa0, 0x33, ZC3XX_R086_EXPTIMEHIGH}, /* 00,86,33,cc */ + {0xa0, 0x34, ZC3XX_R087_EXPTIMEMID}, /* 00,87,34,cc */ + {0xa0, 0x35, ZC3XX_R088_EXPTIMELOW}, /* 00,88,35,cc */ + {0xa0, 0xb0, ZC3XX_R08B_I2CDEVICEADDR}, /* 00,8b,b0,cc */ + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,05,cc */ {0xaa, 0x01, 0x0001}, /* 00,01,01,aa */ {0xaa, 0x01, 0x0003}, /* 00,01,03,aa */ {0xaa, 0x01, 0x0001}, /* 00,01,01,aa */ @@ -3280,7 +3283,7 @@ static const struct usb_action MC501CB_InitialScale[] = { {0xaa, 0x11, 0x0001}, /* 00,11,01,aa */ {0xaa, 0x30, 0x0000}, /* 00,30,00,aa */ {0xaa, 0x60, 0x0000}, /* 00,60,00,aa */ - {0xaa, 0xa0, 0x001a}, /* 00,a0,1a,aa */ + {0xaa, 0xa0, ZC3XX_R01A_LASTFRAMESTATE}, /* 00,a0,1a,aa */ {0xaa, 0xa1, 0x0000}, /* 00,a1,00,aa */ {0xaa, 0xa2, 0x003f}, /* 00,a2,3f,aa */ {0xaa, 0xa3, 0x0028}, /* 00,a3,28,aa */ @@ -3312,15 +3315,15 @@ static const struct usb_action MC501CB_InitialScale[] = { {0xaa, 0x3e, 0x006a}, /* 00,3e,6A,aa */ {0xaa, 0x01, 0x0000}, /* 00,01,00,aa */ {0xaa, 0x52, 0x00ff}, /* 00,52,FF,aa */ - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ - {0xa0, 0x0d, 0x0100}, /* 01,00,0d,cc */ - {0xa0, 0x37, 0x0101}, /* 01,01,37,cc */ - {0xa0, 0x06, 0x0189}, /* 01,89,06,cc */ - {0xa0, 0x03, 0x01c5}, /* 01,c5,03,cc */ - {0xa0, 0x13, 0x01cb}, /* 01,cb,13,cc */ - {0xa0, 0x08, 0x0250}, /* 02,50,08,cc */ - {0xa0, 0x08, 0x0301}, /* 03,01,08,cc */ - {0xa0, 0x02, 0x0180}, /* 01,80,02,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* 01,00,0d,cc */ + {0xa0, 0x37, ZC3XX_R101_SENSORCORRECTION}, /* 01,01,37,cc */ + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, /* 01,89,06,cc */ + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, /* 01,c5,03,cc */ + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, /* 01,cb,13,cc */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* 02,50,08,cc */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* 03,01,08,cc */ + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,02,cc */ {0xaa, 0x03, 0x0002}, /* 00,03,02,aa */ {0xaa, 0x51, 0x0027}, /* 00,51,27,aa */ {0xaa, 0x52, 0x0020}, /* 00,52,20,aa */ @@ -3341,30 +3344,30 @@ static const struct usb_action MC501CB_InitialScale[] = { }; static const struct usb_action MC501CB_Initial[] = { /* 320x240 */ - {0xa0, 0x01, 0x0000}, /* 00,00,01,cc */ - {0xa0, 0x10, 0x0002}, /* 00,02,10,cc */ - {0xa0, 0x01, 0x0010}, /* 00,10,01,cc */ - {0xa0, 0x01, 0x0001}, /* 00,01,01,cc */ - {0xa0, 0x03, 0x0008}, /* 00,08,03,cc */ - {0xa0, 0x01, 0x0012}, /* 00,12,01,cc */ - {0xa0, 0x05, 0x0012}, /* 00,12,05,cc */ - {0xa0, 0x02, 0x0003}, /* 00,03,02,cc */ - {0xa0, 0x80, 0x0004}, /* 00,04,80,cc */ - {0xa0, 0x01, 0x0005}, /* 00,05,01,cc */ - {0xa0, 0xd0, 0x0006}, /* 00,06,d0,cc */ - {0xa0, 0x00, 0x0098}, /* 00,98,00,cc */ - {0xa0, 0x00, 0x009a}, /* 00,9a,00,cc */ - {0xa0, 0x00, 0x011a}, /* 01,1a,00,cc */ - {0xa0, 0x00, 0x011c}, /* 01,1c,00,cc */ - {0xa0, 0x01, 0x009b}, /* 00,9b,01,cc */ - {0xa0, 0xd8, 0x009c}, /* 00,9c,d8,cc */ - {0xa0, 0x02, 0x009d}, /* 00,9d,02,cc */ - {0xa0, 0x88, 0x009e}, /* 00,9e,88,cc */ - {0xa0, 0x33, 0x0086}, /* 00,86,33,cc */ - {0xa0, 0x34, 0x0087}, /* 00,87,34,cc */ - {0xa0, 0x35, 0x0088}, /* 00,88,35,cc */ - {0xa0, 0xb0, 0x008b}, /* 00,8b,b0,cc */ - {0xa0, 0x05, 0x0012}, /* 00,12,05,cc */ + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, /* 00,00,01,cc */ + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, /* 00,02,10,cc */ + {0xa0, 0x01, ZC3XX_R010_CMOSSENSORSELECT}, /* 00,10,01,cc */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, /* 00,01,01,cc */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00,08,03,cc */ + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,01,cc */ + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,05,cc */ + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, /* 00,03,02,cc */ + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, /* 00,04,80,cc */ + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, /* 00,05,01,cc */ + {0xa0, 0xd0, ZC3XX_R006_FRAMEHEIGHTLOW}, /* 00,06,d0,cc */ + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, /* 00,98,00,cc */ + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, /* 00,9a,00,cc */ + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, /* 01,1a,00,cc */ + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, /* 01,1c,00,cc */ + {0xa0, 0x01, ZC3XX_R09B_WINHEIGHTHIGH}, /* 00,9b,01,cc */ + {0xa0, 0xd8, ZC3XX_R09C_WINHEIGHTLOW}, /* 00,9c,d8,cc */ + {0xa0, 0x02, ZC3XX_R09D_WINWIDTHHIGH}, /* 00,9d,02,cc */ + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, /* 00,9e,88,cc */ + {0xa0, 0x33, ZC3XX_R086_EXPTIMEHIGH}, /* 00,86,33,cc */ + {0xa0, 0x34, ZC3XX_R087_EXPTIMEMID}, /* 00,87,34,cc */ + {0xa0, 0x35, ZC3XX_R088_EXPTIMELOW}, /* 00,88,35,cc */ + {0xa0, 0xb0, ZC3XX_R08B_I2CDEVICEADDR}, /* 00,8b,b0,cc */ + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,05,cc */ {0xaa, 0x01, 0x0001}, /* 00,01,01,aa */ {0xaa, 0x01, 0x0003}, /* 00,01,03,aa */ {0xaa, 0x01, 0x0001}, /* 00,01,01,aa */ @@ -3400,7 +3403,7 @@ static const struct usb_action MC501CB_Initial[] = { /* 320x240 */ {0xaa, 0x11, 0x0001}, /* 00,11,01,aa */ {0xaa, 0x30, 0x0000}, /* 00,30,00,aa */ {0xaa, 0x60, 0x0000}, /* 00,60,00,aa */ - {0xaa, 0xa0, 0x001a}, /* 00,a0,1a,aa */ + {0xaa, 0xa0, ZC3XX_R01A_LASTFRAMESTATE}, /* 00,a0,1a,aa */ {0xaa, 0xa1, 0x0000}, /* 00,a1,00,aa */ {0xaa, 0xa2, 0x003f}, /* 00,a2,3f,aa */ {0xaa, 0xa3, 0x0028}, /* 00,a3,28,aa */ @@ -3432,15 +3435,15 @@ static const struct usb_action MC501CB_Initial[] = { /* 320x240 */ {0xaa, 0x3e, 0x00d4}, /* 00,3E,D4,aa */ {0xaa, 0x01, 0x0000}, /* 00,01,00,aa */ {0xaa, 0x52, 0x00ff}, /* 00,52,FF,aa */ - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ - {0xa0, 0x0d, 0x0100}, /* 01,00,0d,cc */ - {0xa0, 0x37, 0x0101}, /* 01,01,37,cc */ - {0xa0, 0x06, 0x0189}, /* 01,89,06,cc */ - {0xa0, 0x03, 0x01c5}, /* 01,c5,03,cc */ - {0xa0, 0x13, 0x01cb}, /* 01,cb,13,cc */ - {0xa0, 0x08, 0x0250}, /* 02,50,08,cc */ - {0xa0, 0x08, 0x0301}, /* 03,01,08,cc */ - {0xa0, 0x02, 0x0180}, /* 01,80,02,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* 01,00,0d,cc */ + {0xa0, 0x37, ZC3XX_R101_SENSORCORRECTION}, /* 01,01,37,cc */ + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, /* 01,89,06,cc */ + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, /* 01,c5,03,cc */ + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, /* 01,cb,13,cc */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* 02,50,08,cc */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* 03,01,08,cc */ + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,02,cc */ {0xaa, 0x03, 0x0002}, /* 00,03,02,aa */ {0xaa, 0x51, 0x004e}, /* 00,51,4E,aa */ {0xaa, 0x52, 0x0041}, /* 00,52,41,aa */ @@ -3558,34 +3561,35 @@ static const struct usb_action MC501CB_NoFlikerScale[] = { /* from zs211.inf - HKR,%OV7620%,Initial - 640x480 */ static const struct usb_action OV7620_mode0[] = { - {0xa0, 0x01, 0x0000}, /* 00,00,01,cc */ - {0xa0, 0x40, 0x0002}, /* 00,02,40,cc */ + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, /* 00,00,01,cc */ + {0xa0, 0x40, ZC3XX_R002_CLOCKSELECT}, /* 00,02,40,cc */ #if 1 /*jfm*/ - {0xa0, 0x00, 0x0008}, /* 00,08,00,cc */ + {0xa0, 0x00, ZC3XX_R008_CLOCKSETTING}, /* 00,08,00,cc */ #else - {0xa0, 0x03, 0x0008}, /* 00,08,00,cc */ /* mx change? */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00,08,00,cc */ + /* mx change? */ #endif - {0xa0, 0x01, 0x0001}, /* 00,01,01,cc */ - {0xa0, 0x06, 0x0010}, /* 00,10,06,cc */ - {0xa0, 0x02, 0x0083}, /* 00,83,02,cc */ - {0xa0, 0x01, 0x0085}, /* 00,85,01,cc */ - {0xa0, 0x80, 0x0086}, /* 00,86,80,cc */ - {0xa0, 0x81, 0x0087}, /* 00,87,81,cc */ - {0xa0, 0x10, 0x0088}, /* 00,88,10,cc */ - {0xa0, 0xa1, 0x008b}, /* 00,8b,a1,cc */ - {0xa0, 0x08, 0x008d}, /* 00,8d,08,cc */ - {0xa0, 0x02, 0x0003}, /* 00,03,02,cc */ - {0xa0, 0x80, 0x0004}, /* 00,04,80,cc */ - {0xa0, 0x01, 0x0005}, /* 00,05,01,cc */ - {0xa0, 0xd8, 0x0006}, /* 00,06,d8,cc */ - {0xa0, 0x03, 0x0012}, /* 00,12,03,cc */ - {0xa0, 0x01, 0x0012}, /* 00,12,01,cc */ - {0xa0, 0x00, 0x0098}, /* 00,98,00,cc */ - {0xa0, 0x00, 0x009a}, /* 00,9a,00,cc */ - {0xa0, 0x00, 0x011a}, /* 01,1a,00,cc */ - {0xa0, 0x00, 0x011c}, /* 01,1c,00,cc */ - {0xa0, 0xde, 0x009c}, /* 00,9c,de,cc */ - {0xa0, 0x86, 0x009e}, /* 00,9e,86,cc */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, /* 00,01,01,cc */ + {0xa0, 0x06, ZC3XX_R010_CMOSSENSORSELECT}, /* 00,10,06,cc */ + {0xa0, 0x02, ZC3XX_R083_RGAINADDR}, /* 00,83,02,cc */ + {0xa0, 0x01, ZC3XX_R085_BGAINADDR}, /* 00,85,01,cc */ + {0xa0, 0x80, ZC3XX_R086_EXPTIMEHIGH}, /* 00,86,80,cc */ + {0xa0, 0x81, ZC3XX_R087_EXPTIMEMID}, /* 00,87,81,cc */ + {0xa0, 0x10, ZC3XX_R088_EXPTIMELOW}, /* 00,88,10,cc */ + {0xa0, 0xa1, ZC3XX_R08B_I2CDEVICEADDR}, /* 00,8b,a1,cc */ + {0xa0, 0x08, ZC3XX_R08D_COMPABILITYMODE}, /* 00,8d,08,cc */ + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, /* 00,03,02,cc */ + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, /* 00,04,80,cc */ + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, /* 00,05,01,cc */ + {0xa0, 0xd8, ZC3XX_R006_FRAMEHEIGHTLOW}, /* 00,06,d8,cc */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,03,cc */ + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,01,cc */ + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, /* 00,98,00,cc */ + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, /* 00,9a,00,cc */ + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, /* 01,1a,00,cc */ + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, /* 01,1c,00,cc */ + {0xa0, 0xde, ZC3XX_R09C_WINHEIGHTLOW}, /* 00,9c,de,cc */ + {0xa0, 0x86, ZC3XX_R09E_WINWIDTHLOW}, /* 00,9e,86,cc */ {0xaa, 0x12, 0x0088}, /* 00,12,88,aa */ {0xaa, 0x12, 0x0048}, /* 00,12,48,aa */ {0xaa, 0x75, 0x008a}, /* 00,75,8a,aa */ @@ -3614,49 +3618,51 @@ static const struct usb_action OV7620_mode0[] = { {0xaa, 0x06, 0x0080}, /* 00,06,80,aa */ {0xaa, 0x01, 0x0090}, /* 00,01,90,aa */ {0xaa, 0x02, 0x0030}, /* 00,02,30,aa */ - {0xa0, 0x77, 0x0101}, /* 01,01,77,cc */ - {0xa0, 0x05, 0x0012}, /* 00,12,05,cc */ - {0xa0, 0x0d, 0x0100}, /* 01,00,0d,cc */ - {0xa0, 0x06, 0x0189}, /* 01,89,06,cc */ + {0xa0, 0x77, ZC3XX_R101_SENSORCORRECTION}, /* 01,01,77,cc */ + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,05,cc */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* 01,00,0d,cc */ + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, /* 01,89,06,cc */ {0xa0, 0x00, 0x01ad}, /* 01,ad,00,cc */ - {0xa0, 0x03, 0x01c5}, /* 01,c5,03,cc */ - {0xa0, 0x13, 0x01cb}, /* 01,cb,13,cc */ - {0xa0, 0x08, 0x0250}, /* 02,50,08,cc */ - {0xa0, 0x08, 0x0301}, /* 03,01,08,cc */ - {0xa0, 0x68, 0x0116}, /* 01,16,68,cc */ - {0xa0, 0x52, 0x0118}, /* 01,18,52,cc */ - {0xa0, 0x40, 0x011d}, /* 01,1d,40,cc */ - {0xa0, 0x02, 0x0180}, /* 01,80,02,cc */ - {0xa0, 0x50, 0x01a8}, /* 01,a8,50,cc */ + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, /* 01,c5,03,cc */ + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, /* 01,cb,13,cc */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* 02,50,08,cc */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* 03,01,08,cc */ + {0xa0, 0x68, ZC3XX_R116_RGAIN}, /* 01,16,68,cc */ + {0xa0, 0x52, ZC3XX_R118_BGAIN}, /* 01,18,52,cc */ + {0xa0, 0x40, ZC3XX_R11D_GLOBALGAIN}, /* 01,1d,40,cc */ + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,02,cc */ + {0xa0, 0x50, ZC3XX_R1A8_DIGITALGAIN}, /* 01,a8,50,cc */ {} }; /* from zs211.inf - HKR,%OV7620%,InitialScale - 320x240 */ static const struct usb_action OV7620_mode1[] = { - {0xa0, 0x01, 0x0000}, /* 00,00,01,cc */ - {0xa0, 0x50, 0x0002}, /* 00,02,50,cc */ - {0xa0, 0x03, 0x0008}, /* 00,08,00,cc */ /* mx change? */ - {0xa0, 0x01, 0x0001}, /* 00,01,01,cc */ - {0xa0, 0x06, 0x0010}, /* 00,10,06,cc */ - {0xa0, 0x02, 0x0083}, /* 00,83,02,cc */ - {0xa0, 0x01, 0x0085}, /* 00,85,01,cc */ - {0xa0, 0x80, 0x0086}, /* 00,86,80,cc */ - {0xa0, 0x81, 0x0087}, /* 00,87,81,cc */ - {0xa0, 0x10, 0x0088}, /* 00,88,10,cc */ - {0xa0, 0xa1, 0x008b}, /* 00,8b,a1,cc */ - {0xa0, 0x08, 0x008d}, /* 00,8d,08,cc */ - {0xa0, 0x02, 0x0003}, /* 00,03,02,cc */ - {0xa0, 0x80, 0x0004}, /* 00,04,80,cc */ - {0xa0, 0x01, 0x0005}, /* 00,05,01,cc */ - {0xa0, 0xd0, 0x0006}, /* 00,06,d0,cc */ - {0xa0, 0x03, 0x0012}, /* 00,12,03,cc */ - {0xa0, 0x01, 0x0012}, /* 00,12,01,cc */ - {0xa0, 0x00, 0x0098}, /* 00,98,00,cc */ - {0xa0, 0x00, 0x009a}, /* 00,9a,00,cc */ - {0xa0, 0x00, 0x011a}, /* 01,1a,00,cc */ - {0xa0, 0x00, 0x011c}, /* 01,1c,00,cc */ - {0xa0, 0xd6, 0x009c}, /* 00,9c,d6,cc */ /* OV7648 00,9c,d8,cc */ - {0xa0, 0x88, 0x009e}, /* 00,9e,88,cc */ + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, /* 00,00,01,cc */ + {0xa0, 0x50, ZC3XX_R002_CLOCKSELECT}, /* 00,02,50,cc */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00,08,00,cc */ + /* mx change? */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, /* 00,01,01,cc */ + {0xa0, 0x06, ZC3XX_R010_CMOSSENSORSELECT}, /* 00,10,06,cc */ + {0xa0, 0x02, ZC3XX_R083_RGAINADDR}, /* 00,83,02,cc */ + {0xa0, 0x01, ZC3XX_R085_BGAINADDR}, /* 00,85,01,cc */ + {0xa0, 0x80, ZC3XX_R086_EXPTIMEHIGH}, /* 00,86,80,cc */ + {0xa0, 0x81, ZC3XX_R087_EXPTIMEMID}, /* 00,87,81,cc */ + {0xa0, 0x10, ZC3XX_R088_EXPTIMELOW}, /* 00,88,10,cc */ + {0xa0, 0xa1, ZC3XX_R08B_I2CDEVICEADDR}, /* 00,8b,a1,cc */ + {0xa0, 0x08, ZC3XX_R08D_COMPABILITYMODE}, /* 00,8d,08,cc */ + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, /* 00,03,02,cc */ + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, /* 00,04,80,cc */ + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, /* 00,05,01,cc */ + {0xa0, 0xd0, ZC3XX_R006_FRAMEHEIGHTLOW}, /* 00,06,d0,cc */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,03,cc */ + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,01,cc */ + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, /* 00,98,00,cc */ + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, /* 00,9a,00,cc */ + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, /* 01,1a,00,cc */ + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, /* 01,1c,00,cc */ + {0xa0, 0xd6, ZC3XX_R09C_WINHEIGHTLOW}, /* 00,9c,d6,cc */ + /* OV7648 00,9c,d8,cc */ + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, /* 00,9e,88,cc */ {0xaa, 0x12, 0x0088}, /* 00,12,88,aa */ {0xaa, 0x12, 0x0048}, /* 00,12,48,aa */ {0xaa, 0x75, 0x008a}, /* 00,75,8a,aa */ @@ -3685,20 +3691,20 @@ static const struct usb_action OV7620_mode1[] = { {0xaa, 0x06, 0x0080}, /* 00,06,80,aa */ {0xaa, 0x01, 0x0090}, /* 00,01,90,aa */ {0xaa, 0x02, 0x0030}, /* 00,02,30,aa */ - {0xa0, 0x77, 0x0101}, /* 01,01,77,cc */ - {0xa0, 0x05, 0x0012}, /* 00,12,05,cc */ - {0xa0, 0x0d, 0x0100}, /* 01,00,0d,cc */ - {0xa0, 0x06, 0x0189}, /* 01,89,06,cc */ - {0xa0, 0x00, 0x01ad}, /* 01,ad,00,cc */ - {0xa0, 0x03, 0x01c5}, /* 01,c5,03,cc */ - {0xa0, 0x13, 0x01cb}, /* 01,cb,13,cc */ - {0xa0, 0x08, 0x0250}, /* 02,50,08,cc */ - {0xa0, 0x08, 0x0301}, /* 03,01,08,cc */ - {0xa0, 0x68, 0x0116}, /* 01,16,68,cc */ - {0xa0, 0x52, 0x0118}, /* 01,18,52,cc */ - {0xa0, 0x50, 0x011d}, /* 01,1d,50,cc */ - {0xa0, 0x02, 0x0180}, /* 01,80,02,cc */ - {0xa0, 0x50, 0x01a8}, /* 01,a8,50,cc */ + {0xa0, 0x77, ZC3XX_R101_SENSORCORRECTION}, /* 01,01,77,cc */ + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,05,cc */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* 01,00,0d,cc */ + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, /* 01,89,06,cc */ + {0xa0, 0x00, 0x01ad}, /* 01,ad,00,cc */ + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, /* 01,c5,03,cc */ + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, /* 01,cb,13,cc */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* 02,50,08,cc */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* 03,01,08,cc */ + {0xa0, 0x68, ZC3XX_R116_RGAIN}, /* 01,16,68,cc */ + {0xa0, 0x52, ZC3XX_R118_BGAIN}, /* 01,18,52,cc */ + {0xa0, 0x50, ZC3XX_R11D_GLOBALGAIN}, /* 01,1d,50,cc */ + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,02,cc */ + {0xa0, 0x50, ZC3XX_R1A8_DIGITALGAIN}, /* 01,a8,50,cc */ {} }; @@ -3709,34 +3715,37 @@ static const struct usb_action OV7620_50HZ[] = { {0xaa, 0x2b, 0x0096}, /* 00,2b,96,aa */ {0xaa, 0x75, 0x008a}, /* 00,75,8a,aa */ {0xaa, 0x2d, 0x0005}, /* 00,2d,05,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x04, 0x0191}, /* 01,91,04,cc */ - {0xa0, 0x18, 0x0192}, /* 01,92,18,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x83, 0x0197}, /* 01,97,83,cc */ - {0xaa, 0x10, 0x0082}, /* 00,10,82,aa */ - {0xaa, 0x76, 0x0003}, /* 00,76,03,aa */ -/* {0xa0, 0x40, 0x0002}, * 00,02,40,cc - if mode0 (640x480) */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,04,cc */ + {0xa0, 0x18, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,18,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x83, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,83,cc */ + {0xaa, 0x10, 0x0082}, /* 00,10,82,aa */ + {0xaa, 0x76, 0x0003}, /* 00,76,03,aa */ +/* {0xa0, 0x40, ZC3XX_R002_CLOCKSELECT}, * 00,02,40,cc + if mode0 (640x480) */ {} }; /* from zs211.inf - HKR,%OV7620%\AE,60HZ */ static const struct usb_action OV7620_60HZ[] = { - {0xaa, 0x13, 0x00a3}, /* 00,13,a3,aa */ /* (bug in zs211.inf) */ - {0xdd, 0x00, 0x0100}, /* 00,01,00,dd */ - {0xaa, 0x2b, 0x0000}, /* 00,2b,00,aa */ - {0xaa, 0x75, 0x008a}, /* 00,75,8a,aa */ - {0xaa, 0x2d, 0x0005}, /* 00,2d,05,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x04, 0x0191}, /* 01,91,04,cc */ - {0xa0, 0x18, 0x0192}, /* 01,92,18,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x83, 0x0197}, /* 01,97,83,cc */ - {0xaa, 0x10, 0x0020}, /* 00,10,20,aa */ - {0xaa, 0x76, 0x0003}, /* 00,76,03,aa */ -/* {0xa0, 0x40, 0x0002}, * 00,02,40,cc - if mode0 (640x480) */ + {0xaa, 0x13, 0x00a3}, /* 00,13,a3,aa */ + /* (bug in zs211.inf) */ + {0xdd, 0x00, 0x0100}, /* 00,01,00,dd */ + {0xaa, 0x2b, 0x0000}, /* 00,2b,00,aa */ + {0xaa, 0x75, 0x008a}, /* 00,75,8a,aa */ + {0xaa, 0x2d, 0x0005}, /* 00,2d,05,aa */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,04,cc */ + {0xa0, 0x18, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,18,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x83, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,83,cc */ + {0xaa, 0x10, 0x0020}, /* 00,10,20,aa */ + {0xaa, 0x76, 0x0003}, /* 00,76,03,aa */ +/* {0xa0, 0x40, ZC3XX_R002_CLOCKSELECT}, * 00,02,40,cc + * if mode0 (640x480) */ /* ?? in gspca v1, it was {0xa0, 0x00, 0x0039}, * 00,00,00,dd * {0xa1, 0x01, 0x0037}, */ @@ -3745,18 +3754,20 @@ static const struct usb_action OV7620_60HZ[] = { /* from zs211.inf - HKR,%OV7620%\AE,NoFliker */ static const struct usb_action OV7620_NoFliker[] = { - {0xaa, 0x13, 0x00a3}, /* 00,13,a3,aa */ /* (bug in zs211.inf) */ - {0xdd, 0x00, 0x0100}, /* 00,01,00,dd */ - {0xaa, 0x2b, 0x0000}, /* 00,2b,00,aa */ - {0xaa, 0x75, 0x008e}, /* 00,75,8e,aa */ - {0xaa, 0x2d, 0x0001}, /* 00,2d,01,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x04, 0x0191}, /* 01,91,04,cc */ - {0xa0, 0x18, 0x0192}, /* 01,92,18,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x01, 0x0197}, /* 01,97,01,cc */ -/* {0xa0, 0x44, 0x0002}, * 00,02,44,cc - if mode1 (320x240) */ + {0xaa, 0x13, 0x00a3}, /* 00,13,a3,aa */ + /* (bug in zs211.inf) */ + {0xdd, 0x00, 0x0100}, /* 00,01,00,dd */ + {0xaa, 0x2b, 0x0000}, /* 00,2b,00,aa */ + {0xaa, 0x75, 0x008e}, /* 00,75,8e,aa */ + {0xaa, 0x2d, 0x0001}, /* 00,2d,01,aa */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x04, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,04,cc */ + {0xa0, 0x18, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,18,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x01, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,01,cc */ +/* {0xa0, 0x44, ZC3XX_R002_CLOCKSELECT}, * 00,02,44,cc + - if mode1 (320x240) */ /* ?? was {0xa0, 0x00, 0x0039}, * 00,00,00,dd * {0xa1, 0x01, 0x0037}, */ @@ -3764,32 +3775,32 @@ static const struct usb_action OV7620_NoFliker[] = { }; static const struct usb_action ov7630c_Initial[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x10, 0x0002}, - {0xa0, 0x01, 0x0000}, - {0xa0, 0x10, 0x0002}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x06, 0x0010}, - {0xa0, 0xa1, 0x008b}, - {0xa0, 0x08, 0x008d}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x01, 0x0012}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x06, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0xa1, ZC3XX_R08B_I2CDEVICEADDR}, + {0xa0, 0x08, ZC3XX_R08D_COMPABILITYMODE}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, {0xaa, 0x12, 0x0080}, - {0xa0, 0x02, 0x0083}, - {0xa0, 0x01, 0x0085}, - {0xa0, 0x90, 0x0086}, - {0xa0, 0x91, 0x0087}, - {0xa0, 0x10, 0x0088}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0xd8, 0x009c}, - {0xa0, 0x88, 0x009e}, + {0xa0, 0x02, ZC3XX_R083_RGAINADDR}, + {0xa0, 0x01, ZC3XX_R085_BGAINADDR}, + {0xa0, 0x90, ZC3XX_R086_EXPTIMEHIGH}, + {0xa0, 0x91, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x10, ZC3XX_R088_EXPTIMELOW}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0xd8, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, {0xaa, 0x12, 0x0069}, {0xaa, 0x04, 0x0020}, {0xaa, 0x06, 0x0050}, @@ -3821,131 +3832,131 @@ static const struct usb_action ov7630c_Initial[] = { {0xaa, 0x77, 0x00b5}, {0xaa, 0x01, 0x0060}, {0xaa, 0x02, 0x0060}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x77, 0x0101}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x04, 0x01a7}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x77, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, {0xa0, 0x00, 0x01ad}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, - {0xa0, 0x60, 0x0116}, - {0xa0, 0x46, 0x0118}, - {0xa0, 0x04, 0x0113}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, + {0xa0, 0x60, ZC3XX_R116_RGAIN}, + {0xa0, 0x46, ZC3XX_R118_BGAIN}, + {0xa0, 0x04, ZC3XX_R113_RGB03}, /* 0x10, */ {0xa1, 0x01, 0x0002}, - {0xa0, 0x50, 0x010a}, /* matrix */ - {0xa0, 0xf8, 0x010b}, - {0xa0, 0xf8, 0x010c}, - {0xa0, 0xf8, 0x010d}, - {0xa0, 0x50, 0x010e}, - {0xa0, 0xf8, 0x010f}, - {0xa0, 0xf8, 0x0110}, - {0xa0, 0xf8, 0x0111}, - {0xa0, 0x50, 0x0112}, + {0xa0, 0x50, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf8, ZC3XX_R10B_RGB01}, + {0xa0, 0xf8, ZC3XX_R10C_RGB02}, + {0xa0, 0xf8, ZC3XX_R10D_RGB10}, + {0xa0, 0x50, ZC3XX_R10E_RGB11}, + {0xa0, 0xf8, ZC3XX_R10F_RGB12}, + {0xa0, 0xf8, ZC3XX_R110_RGB20}, + {0xa0, 0xf8, ZC3XX_R111_RGB21}, + {0xa0, 0x50, ZC3XX_R112_RGB22}, /* 0x03, */ {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - {0xa0, 0x01, 0x0120}, /* gamma 2 ?*/ - {0xa0, 0x0c, 0x0121}, - {0xa0, 0x1f, 0x0122}, - {0xa0, 0x3a, 0x0123}, - {0xa0, 0x53, 0x0124}, - {0xa0, 0x6d, 0x0125}, - {0xa0, 0x85, 0x0126}, - {0xa0, 0x9c, 0x0127}, - {0xa0, 0xb0, 0x0128}, - {0xa0, 0xc2, 0x0129}, - {0xa0, 0xd1, 0x012a}, - {0xa0, 0xde, 0x012b}, - {0xa0, 0xe9, 0x012c}, - {0xa0, 0xf2, 0x012d}, - {0xa0, 0xf9, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x05, 0x0130}, - {0xa0, 0x0f, 0x0131}, - {0xa0, 0x16, 0x0132}, - {0xa0, 0x1a, 0x0133}, - {0xa0, 0x19, 0x0134}, - {0xa0, 0x19, 0x0135}, - {0xa0, 0x17, 0x0136}, - {0xa0, 0x15, 0x0137}, - {0xa0, 0x12, 0x0138}, - {0xa0, 0x10, 0x0139}, - {0xa0, 0x0e, 0x013a}, - {0xa0, 0x0b, 0x013b}, - {0xa0, 0x09, 0x013c}, - {0xa0, 0x08, 0x013d}, - {0xa0, 0x06, 0x013e}, - {0xa0, 0x03, 0x013f}, - {0xa0, 0x50, 0x010a}, /* matrix */ - {0xa0, 0xf8, 0x010b}, - {0xa0, 0xf8, 0x010c}, - {0xa0, 0xf8, 0x010d}, - {0xa0, 0x50, 0x010e}, - {0xa0, 0xf8, 0x010f}, - {0xa0, 0xf8, 0x0110}, - {0xa0, 0xf8, 0x0111}, - {0xa0, 0x50, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x01, ZC3XX_R120_GAMMA00}, /* gamma 2 ?*/ + {0xa0, 0x0c, ZC3XX_R121_GAMMA01}, + {0xa0, 0x1f, ZC3XX_R122_GAMMA02}, + {0xa0, 0x3a, ZC3XX_R123_GAMMA03}, + {0xa0, 0x53, ZC3XX_R124_GAMMA04}, + {0xa0, 0x6d, ZC3XX_R125_GAMMA05}, + {0xa0, 0x85, ZC3XX_R126_GAMMA06}, + {0xa0, 0x9c, ZC3XX_R127_GAMMA07}, + {0xa0, 0xb0, ZC3XX_R128_GAMMA08}, + {0xa0, 0xc2, ZC3XX_R129_GAMMA09}, + {0xa0, 0xd1, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xde, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xe9, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xf2, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xf9, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x05, ZC3XX_R130_GAMMA10}, + {0xa0, 0x0f, ZC3XX_R131_GAMMA11}, + {0xa0, 0x16, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1a, ZC3XX_R133_GAMMA13}, + {0xa0, 0x19, ZC3XX_R134_GAMMA14}, + {0xa0, 0x19, ZC3XX_R135_GAMMA15}, + {0xa0, 0x17, ZC3XX_R136_GAMMA16}, + {0xa0, 0x15, ZC3XX_R137_GAMMA17}, + {0xa0, 0x12, ZC3XX_R138_GAMMA18}, + {0xa0, 0x10, ZC3XX_R139_GAMMA19}, + {0xa0, 0x0e, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x0b, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x09, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x08, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x06, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x03, ZC3XX_R13F_GAMMA1F}, + {0xa0, 0x50, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf8, ZC3XX_R10B_RGB01}, + {0xa0, 0xf8, ZC3XX_R10C_RGB02}, + {0xa0, 0xf8, ZC3XX_R10D_RGB10}, + {0xa0, 0x50, ZC3XX_R10E_RGB11}, + {0xa0, 0xf8, ZC3XX_R10F_RGB12}, + {0xa0, 0xf8, ZC3XX_R110_RGB20}, + {0xa0, 0xf8, ZC3XX_R111_RGB21}, + {0xa0, 0x50, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, {0xaa, 0x10, 0x001b}, {0xaa, 0x76, 0x0002}, {0xaa, 0x2a, 0x0081}, {0xaa, 0x2b, 0x0000}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x01, 0x0191}, - {0xa0, 0xb8, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x37, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x10, 0x01a9}, - {0xa0, 0x26, 0x01aa}, - {0xa0, 0x50, 0x011d}, - {0xa0, 0x02, 0x0180}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x01, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0xb8, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x37, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x26, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x50, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xaa, 0x13, 0x0083}, /* 40 */ {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {} }; static const struct usb_action ov7630c_InitialScale[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x00, 0x0002}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x06, 0x0010}, - {0xa0, 0xa1, 0x008b}, - {0xa0, 0x08, 0x008d}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x01, 0x0012}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x06, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0xa1, ZC3XX_R08B_I2CDEVICEADDR}, + {0xa0, 0x08, ZC3XX_R08D_COMPABILITYMODE}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, {0xaa, 0x12, 0x0080}, - {0xa0, 0x02, 0x0083}, - {0xa0, 0x01, 0x0085}, - {0xa0, 0x90, 0x0086}, - {0xa0, 0x91, 0x0087}, - {0xa0, 0x10, 0x0088}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0xe6, 0x009c}, - {0xa0, 0x86, 0x009e}, + {0xa0, 0x02, ZC3XX_R083_RGAINADDR}, + {0xa0, 0x01, ZC3XX_R085_BGAINADDR}, + {0xa0, 0x90, ZC3XX_R086_EXPTIMEHIGH}, + {0xa0, 0x91, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x10, ZC3XX_R088_EXPTIMELOW}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0xe6, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x86, ZC3XX_R09E_WINWIDTHLOW}, {0xaa, 0x12, 0x0069}, /* i2c */ {0xaa, 0x04, 0x0020}, {0xaa, 0x06, 0x0050}, @@ -3977,103 +3988,103 @@ static const struct usb_action ov7630c_InitialScale[] = { {0xaa, 0x02, 0x0060}, {0xaa, 0x17, 0x0018}, {0xaa, 0x18, 0x00ba}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x77, 0x0101}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x04, 0x01a7}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x77, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x04, ZC3XX_R1A7_CALCGLOBALMEAN}, {0xa0, 0x00, 0x01ad}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, - {0xa0, 0x60, 0x0116}, - {0xa0, 0x46, 0x0118}, - {0xa0, 0x04, 0x0113}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, + {0xa0, 0x60, ZC3XX_R116_RGAIN}, + {0xa0, 0x46, ZC3XX_R118_BGAIN}, + {0xa0, 0x04, ZC3XX_R113_RGB03}, {0xa1, 0x01, 0x0002}, - {0xa0, 0x4e, 0x010a}, /* matrix */ - {0xa0, 0xfe, 0x010b}, - {0xa0, 0xf4, 0x010c}, - {0xa0, 0xf7, 0x010d}, - {0xa0, 0x4d, 0x010e}, - {0xa0, 0xfc, 0x010f}, - {0xa0, 0x00, 0x0110}, - {0xa0, 0xf6, 0x0111}, - {0xa0, 0x4a, 0x0112}, + {0xa0, 0x4e, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xfe, ZC3XX_R10B_RGB01}, + {0xa0, 0xf4, ZC3XX_R10C_RGB02}, + {0xa0, 0xf7, ZC3XX_R10D_RGB10}, + {0xa0, 0x4d, ZC3XX_R10E_RGB11}, + {0xa0, 0xfc, ZC3XX_R10F_RGB12}, + {0xa0, 0x00, ZC3XX_R110_RGB20}, + {0xa0, 0xf6, ZC3XX_R111_RGB21}, + {0xa0, 0x4a, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - {0xa0, 0x16, 0x0120}, /* gamma ~4 */ - {0xa0, 0x3a, 0x0121}, - {0xa0, 0x5b, 0x0122}, - {0xa0, 0x7c, 0x0123}, - {0xa0, 0x94, 0x0124}, - {0xa0, 0xa9, 0x0125}, - {0xa0, 0xbb, 0x0126}, - {0xa0, 0xca, 0x0127}, - {0xa0, 0xd7, 0x0128}, - {0xa0, 0xe1, 0x0129}, - {0xa0, 0xea, 0x012a}, - {0xa0, 0xf1, 0x012b}, - {0xa0, 0xf7, 0x012c}, - {0xa0, 0xfc, 0x012d}, - {0xa0, 0xff, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x20, 0x0130}, - {0xa0, 0x22, 0x0131}, - {0xa0, 0x20, 0x0132}, - {0xa0, 0x1c, 0x0133}, - {0xa0, 0x16, 0x0134}, - {0xa0, 0x13, 0x0135}, - {0xa0, 0x10, 0x0136}, - {0xa0, 0x0d, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x06, 0x013b}, - {0xa0, 0x05, 0x013c}, - {0xa0, 0x04, 0x013d}, - {0xa0, 0x00, 0x013e}, - {0xa0, 0x01, 0x013f}, - {0xa0, 0x4e, 0x010a}, /* matrix */ - {0xa0, 0xfe, 0x010b}, - {0xa0, 0xf4, 0x010c}, - {0xa0, 0xf7, 0x010d}, - {0xa0, 0x4d, 0x010e}, - {0xa0, 0xfc, 0x010f}, - {0xa0, 0x00, 0x0110}, - {0xa0, 0xf6, 0x0111}, - {0xa0, 0x4a, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x16, ZC3XX_R120_GAMMA00}, /* gamma ~4 */ + {0xa0, 0x3a, ZC3XX_R121_GAMMA01}, + {0xa0, 0x5b, ZC3XX_R122_GAMMA02}, + {0xa0, 0x7c, ZC3XX_R123_GAMMA03}, + {0xa0, 0x94, ZC3XX_R124_GAMMA04}, + {0xa0, 0xa9, ZC3XX_R125_GAMMA05}, + {0xa0, 0xbb, ZC3XX_R126_GAMMA06}, + {0xa0, 0xca, ZC3XX_R127_GAMMA07}, + {0xa0, 0xd7, ZC3XX_R128_GAMMA08}, + {0xa0, 0xe1, ZC3XX_R129_GAMMA09}, + {0xa0, 0xea, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xf1, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xf7, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xfc, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xff, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x20, ZC3XX_R130_GAMMA10}, + {0xa0, 0x22, ZC3XX_R131_GAMMA11}, + {0xa0, 0x20, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1c, ZC3XX_R133_GAMMA13}, + {0xa0, 0x16, ZC3XX_R134_GAMMA14}, + {0xa0, 0x13, ZC3XX_R135_GAMMA15}, + {0xa0, 0x10, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0d, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x06, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x05, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x04, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x00, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x01, ZC3XX_R13F_GAMMA1F}, + {0xa0, 0x4e, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xfe, ZC3XX_R10B_RGB01}, + {0xa0, 0xf4, ZC3XX_R10C_RGB02}, + {0xa0, 0xf7, ZC3XX_R10D_RGB10}, + {0xa0, 0x4d, ZC3XX_R10E_RGB11}, + {0xa0, 0xfc, ZC3XX_R10F_RGB12}, + {0xa0, 0x00, ZC3XX_R110_RGB20}, + {0xa0, 0xf6, ZC3XX_R111_RGB21}, + {0xa0, 0x4a, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, {0xaa, 0x10, 0x000d}, {0xaa, 0x76, 0x0002}, {0xaa, 0x2a, 0x0081}, {0xaa, 0x2b, 0x0000}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x00, 0x0191}, - {0xa0, 0xd8, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x1b, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x10, 0x01a9}, - {0xa0, 0x26, 0x01aa}, - {0xa0, 0x50, 0x011d}, - {0xa0, 0x02, 0x0180}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x00, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0xd8, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x1b, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x26, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x50, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xaa, 0x13, 0x00c3}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {} }; @@ -4081,10 +4092,10 @@ static const struct usb_action pas106b_Initial_com[] = { /* Sream and Sensor specific */ {0xa1, 0x01, 0x0010}, /* CMOSSensorSelect */ /* System */ - {0xa0, 0x01, 0x0000}, /* SystemControl */ - {0xa0, 0x01, 0x0000}, /* SystemControl */ + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, /* SystemControl */ + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, /* SystemControl */ /* Picture size */ - {0xa0, 0x00, 0x0002}, /* ClockSelect */ + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, /* ClockSelect */ {0xa0, 0x03, 0x003a}, {0xa0, 0x0c, 0x003b}, {0xa0, 0x04, 0x0038}, @@ -4093,27 +4104,27 @@ static const struct usb_action pas106b_Initial_com[] = { static const struct usb_action pas106b_Initial[] = { /* 176x144 */ /* JPEG control */ - {0xa0, 0x03, 0x0008}, /* ClockSetting */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* Sream and Sensor specific */ - {0xa0, 0x0f, 0x0010}, /* CMOSSensorSelect */ + {0xa0, 0x0f, ZC3XX_R010_CMOSSENSORSELECT}, /* Picture size */ - {0xa0, 0x00, 0x0003}, /* FrameWidthHigh 00 */ - {0xa0, 0xb0, 0x0004}, /* FrameWidthLow B0 */ - {0xa0, 0x00, 0x0005}, /* FrameHeightHigh 00 */ - {0xa0, 0x90, 0x0006}, /* FrameHightLow 90 */ + {0xa0, 0x00, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0xb0, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x00, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0x90, ZC3XX_R006_FRAMEHEIGHTLOW}, /* System */ - {0xa0, 0x01, 0x0001}, /* SystemOperating */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, /* Sream and Sensor specific */ - {0xa0, 0x03, 0x0012}, /* VideoControlFunction */ - {0xa0, 0x01, 0x0012}, /* VideoControlFunction */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, /* Sensor Interface */ - {0xa0, 0x08, 0x008d}, /* Compatibily Mode */ + {0xa0, 0x08, ZC3XX_R08D_COMPABILITYMODE}, /* Window inside sensor array */ - {0xa0, 0x03, 0x009a}, /* WinXStartLow */ - {0xa0, 0x00, 0x011a}, /* FirstYLow */ - {0xa0, 0x03, 0x011c}, /* FirstxLow */ - {0xa0, 0x28, 0x009c}, /* WinHeightLow */ - {0xa0, 0x68, 0x009e}, /* WinWidthLow */ + {0xa0, 0x03, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x03, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0x28, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x68, ZC3XX_R09E_WINWIDTHLOW}, /* Init the sensor */ {0xaa, 0x02, 0x0004}, {0xaa, 0x08, 0x0000}, @@ -4126,112 +4137,112 @@ static const struct usb_action pas106b_Initial[] = { /* 176x144 */ {0xaa, 0x14, 0x0081}, /* Other registors */ - {0xa0, 0x37, 0x0101}, /* SensorCorrection */ + {0xa0, 0x37, ZC3XX_R101_SENSORCORRECTION}, /* Frame retreiving */ - {0xa0, 0x00, 0x0019}, /* AutoAdjustFPS */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* Gains */ - {0xa0, 0xa0, 0x01a8}, /* DigitalGain */ + {0xa0, 0xa0, ZC3XX_R1A8_DIGITALGAIN}, /* Unknown */ {0xa0, 0x00, 0x01ad}, /* Sharpness */ - {0xa0, 0x03, 0x01c5}, /* SharpnessMode */ - {0xa0, 0x13, 0x01cb}, /* Sharpness05 */ + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, /* Other registors */ - {0xa0, 0x0d, 0x0100}, /* OperationMode */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* Auto exposure and white balance */ - {0xa0, 0x06, 0x0189}, /* AWBStatus */ + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, /*Dead pixels */ - {0xa0, 0x08, 0x0250}, /* DeadPixelsMode */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* EEPROM */ - {0xa0, 0x08, 0x0301}, /* EEPROMAccess */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* JPEG control */ - {0xa0, 0x03, 0x0008}, /* ClockSetting */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* Other registers */ - {0xa0, 0x0d, 0x0100}, /* OperationMode */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* Auto exposure and white balance */ - {0xa0, 0x06, 0x0189}, /* AWBStatus */ + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, /*Dead pixels */ - {0xa0, 0x08, 0x0250}, /* DeadPixelsMode */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* EEPROM */ - {0xa0, 0x08, 0x0301}, /* EEPROMAccess */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* JPEG control */ - {0xa0, 0x03, 0x0008}, /* ClockSetting */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - - {0xa0, 0x58, 0x010a}, /* matrix */ - {0xa0, 0xf4, 0x010b}, - {0xa0, 0xf4, 0x010c}, - {0xa0, 0xf4, 0x010d}, - {0xa0, 0x58, 0x010e}, - {0xa0, 0xf4, 0x010f}, - {0xa0, 0xf4, 0x0110}, - {0xa0, 0xf4, 0x0111}, - {0xa0, 0x58, 0x0112}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, + + {0xa0, 0x58, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf4, ZC3XX_R10B_RGB01}, + {0xa0, 0xf4, ZC3XX_R10C_RGB02}, + {0xa0, 0xf4, ZC3XX_R10D_RGB10}, + {0xa0, 0x58, ZC3XX_R10E_RGB11}, + {0xa0, 0xf4, ZC3XX_R10F_RGB12}, + {0xa0, 0xf4, ZC3XX_R110_RGB20}, + {0xa0, 0xf4, ZC3XX_R111_RGB21}, + {0xa0, 0x58, ZC3XX_R112_RGB22}, /* Auto correction */ - {0xa0, 0x03, 0x0181}, /* WinXstart */ - {0xa0, 0x08, 0x0182}, /* WinXWidth */ - {0xa0, 0x16, 0x0183}, /* WinXCenter */ - {0xa0, 0x03, 0x0184}, /* WinYStart */ - {0xa0, 0x05, 0x0185}, /* WinYWidth */ - {0xa0, 0x14, 0x0186}, /* WinYCenter */ - {0xa0, 0x00, 0x0180}, /* AutoCorrectEnable */ + {0xa0, 0x03, ZC3XX_R181_WINXSTART}, + {0xa0, 0x08, ZC3XX_R182_WINXWIDTH}, + {0xa0, 0x16, ZC3XX_R183_WINXCENTER}, + {0xa0, 0x03, ZC3XX_R184_WINYSTART}, + {0xa0, 0x05, ZC3XX_R185_WINYWIDTH}, + {0xa0, 0x14, ZC3XX_R186_WINYCENTER}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, /* Auto exposure and white balance */ - {0xa0, 0x00, 0x0190}, /* ExposureLimitHigh */ - {0xa0, 0x03, 0x0191}, /* ExposureLimitMid */ - {0xa0, 0xb1, 0x0192}, /* ExposureLimitLow */ - {0xa0, 0x00, 0x0195}, /* AntiFlickerHigh */ - {0xa0, 0x00, 0x0196}, /* AntiFlickerLow */ - {0xa0, 0x87, 0x0197}, /* AntiFlickerLow */ - {0xa0, 0x0c, 0x018c}, /* AEBFreeze */ - {0xa0, 0x18, 0x018f}, /* AEBUnfreeze */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x03, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0xb1, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x87, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x0c, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x18, ZC3XX_R18F_AEUNFREEZE}, /* sensor on */ {0xaa, 0x07, 0x00b1}, {0xaa, 0x05, 0x0003}, {0xaa, 0x04, 0x0001}, {0xaa, 0x03, 0x003b}, /* Gains */ - {0xa0, 0x20, 0x01a9}, /* DigitalLimitDiff */ - {0xa0, 0x26, 0x01aa}, /* DigitalGainStep */ - {0xa0, 0xa0, 0x011d}, /* GlobalGain */ - {0xa0, 0x60, 0x011d}, /* GlobalGain */ + {0xa0, 0x20, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x26, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0xa0, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, /* Auto correction */ - {0xa0, 0x40, 0x0180}, /* AutoCorrectEnable */ - {0xa1, 0x01, 0x0180}, /* AutoCorrectEnable */ - {0xa0, 0x42, 0x0180}, /* AutoCorrectEnable */ + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa1, 0x01, 0x0180}, /* AutoCorrectEnable */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, /* Gains */ - {0xa0, 0x40, 0x0116}, /* RGain */ - {0xa0, 0x40, 0x0117}, /* GGain */ - {0xa0, 0x40, 0x0118}, /* BGain */ + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, {} }; static const struct usb_action pas106b_InitialScale[] = { /* 352x288 */ /* JPEG control */ - {0xa0, 0x03, 0x0008}, /* ClockSetting */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* Sream and Sensor specific */ - {0xa0, 0x0f, 0x0010}, /* CMOSSensorSelect */ + {0xa0, 0x0f, ZC3XX_R010_CMOSSENSORSELECT}, /* Picture size */ - {0xa0, 0x01, 0x0003}, /* FrameWidthHigh */ - {0xa0, 0x60, 0x0004}, /* FrameWidthLow */ - {0xa0, 0x01, 0x0005}, /* FrameHeightHigh */ - {0xa0, 0x20, 0x0006}, /* FrameHightLow */ + {0xa0, 0x01, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x60, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0x20, ZC3XX_R006_FRAMEHEIGHTLOW}, /* System */ - {0xa0, 0x01, 0x0001}, /* SystemOperating */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, /* Sream and Sensor specific */ - {0xa0, 0x03, 0x0012}, /* VideoControlFunction */ - {0xa0, 0x01, 0x0012}, /* VideoControlFunction */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, /* Sensor Interface */ - {0xa0, 0x08, 0x008d}, /* Compatibily Mode */ + {0xa0, 0x08, ZC3XX_R08D_COMPABILITYMODE}, /* Window inside sensor array */ - {0xa0, 0x03, 0x009a}, /* WinXStartLow */ - {0xa0, 0x00, 0x011a}, /* FirstYLow */ - {0xa0, 0x03, 0x011c}, /* FirstxLow */ - {0xa0, 0x28, 0x009c}, /* WinHeightLow */ - {0xa0, 0x68, 0x009e}, /* WinWidthLow */ + {0xa0, 0x03, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x03, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0x28, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x68, ZC3XX_R09E_WINWIDTHLOW}, /* Init the sensor */ {0xaa, 0x02, 0x0004}, {0xaa, 0x08, 0x0000}, @@ -4244,161 +4255,161 @@ static const struct usb_action pas106b_InitialScale[] = { /* 352x288 */ {0xaa, 0x14, 0x0081}, /* Other registors */ - {0xa0, 0x37, 0x0101}, /* SensorCorrection */ + {0xa0, 0x37, ZC3XX_R101_SENSORCORRECTION}, /* Frame retreiving */ - {0xa0, 0x00, 0x0019}, /* AutoAdjustFPS */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* Gains */ - {0xa0, 0xa0, 0x01a8}, /* DigitalGain */ + {0xa0, 0xa0, ZC3XX_R1A8_DIGITALGAIN}, /* Unknown */ {0xa0, 0x00, 0x01ad}, /* Sharpness */ - {0xa0, 0x03, 0x01c5}, /* SharpnessMode */ - {0xa0, 0x13, 0x01cb}, /* Sharpness05 */ + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, /* Other registors */ - {0xa0, 0x0d, 0x0100}, /* OperationMode */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* Auto exposure and white balance */ - {0xa0, 0x06, 0x0189}, /* AWBStatus */ - {0xa0, 0x80, 0x018d}, /* ????????? */ + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x80, ZC3XX_R18D_YTARGET}, /*Dead pixels */ - {0xa0, 0x08, 0x0250}, /* DeadPixelsMode */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* EEPROM */ - {0xa0, 0x08, 0x0301}, /* EEPROMAccess */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* JPEG control */ - {0xa0, 0x03, 0x0008}, /* ClockSetting */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* Other registers */ - {0xa0, 0x0d, 0x0100}, /* OperationMode */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* Auto exposure and white balance */ - {0xa0, 0x06, 0x0189}, /* AWBStatus */ + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, /*Dead pixels */ - {0xa0, 0x08, 0x0250}, /* DeadPixelsMode */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* EEPROM */ - {0xa0, 0x08, 0x0301}, /* EEPROMAccess */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* JPEG control */ - {0xa0, 0x03, 0x0008}, /* ClockSetting */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - - {0xa0, 0x58, 0x010a}, /* matrix */ - {0xa0, 0xf4, 0x010b}, - {0xa0, 0xf4, 0x010c}, - {0xa0, 0xf4, 0x010d}, - {0xa0, 0x58, 0x010e}, - {0xa0, 0xf4, 0x010f}, - {0xa0, 0xf4, 0x0110}, - {0xa0, 0xf4, 0x0111}, - {0xa0, 0x58, 0x0112}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, + + {0xa0, 0x58, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf4, ZC3XX_R10B_RGB01}, + {0xa0, 0xf4, ZC3XX_R10C_RGB02}, + {0xa0, 0xf4, ZC3XX_R10D_RGB10}, + {0xa0, 0x58, ZC3XX_R10E_RGB11}, + {0xa0, 0xf4, ZC3XX_R10F_RGB12}, + {0xa0, 0xf4, ZC3XX_R110_RGB20}, + {0xa0, 0xf4, ZC3XX_R111_RGB21}, + {0xa0, 0x58, ZC3XX_R112_RGB22}, /* Auto correction */ - {0xa0, 0x03, 0x0181}, /* WinXstart */ - {0xa0, 0x08, 0x0182}, /* WinXWidth */ - {0xa0, 0x16, 0x0183}, /* WinXCenter */ - {0xa0, 0x03, 0x0184}, /* WinYStart */ - {0xa0, 0x05, 0x0185}, /* WinYWidth */ - {0xa0, 0x14, 0x0186}, /* WinYCenter */ - {0xa0, 0x00, 0x0180}, /* AutoCorrectEnable */ + {0xa0, 0x03, ZC3XX_R181_WINXSTART}, + {0xa0, 0x08, ZC3XX_R182_WINXWIDTH}, + {0xa0, 0x16, ZC3XX_R183_WINXCENTER}, + {0xa0, 0x03, ZC3XX_R184_WINYSTART}, + {0xa0, 0x05, ZC3XX_R185_WINYWIDTH}, + {0xa0, 0x14, ZC3XX_R186_WINYCENTER}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, /* Auto exposure and white balance */ - {0xa0, 0x00, 0x0190}, /* ExposureLimitHigh 0 */ - {0xa0, 0x03, 0x0191}, /* ExposureLimitMid */ - {0xa0, 0xb1, 0x0192}, /* ExposureLimitLow 0xb1 */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x03, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0xb1, ZC3XX_R192_EXPOSURELIMITLOW}, - {0xa0, 0x00, 0x0195}, /* AntiFlickerHigh 0x00 */ - {0xa0, 0x00, 0x0196}, /* AntiFlickerLow 0x00 */ - {0xa0, 0x87, 0x0197}, /* AntiFlickerLow 0x87 */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x87, ZC3XX_R197_ANTIFLICKERLOW}, - {0xa0, 0x10, 0x018c}, /* AEBFreeze 0x10 0x0c */ - {0xa0, 0x20, 0x018f}, /* AEBUnfreeze 0x30 0x18 */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* sensor on */ {0xaa, 0x07, 0x00b1}, {0xaa, 0x05, 0x0003}, {0xaa, 0x04, 0x0001}, {0xaa, 0x03, 0x003b}, /* Gains */ - {0xa0, 0x20, 0x01a9}, /* DigitalLimitDiff */ - {0xa0, 0x26, 0x01aa}, /* DigitalGainStep */ - {0xa0, 0xa0, 0x011d}, /* GlobalGain */ - {0xa0, 0x60, 0x011d}, /* GlobalGain */ + {0xa0, 0x20, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x26, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0xa0, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, /* Auto correction */ - {0xa0, 0x40, 0x0180}, /* AutoCorrectEnable */ - {0xa1, 0x01, 0x0180}, /* AutoCorrectEnable */ - {0xa0, 0x42, 0x0180}, /* AutoCorrectEnable */ + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa1, 0x01, 0x0180}, /* AutoCorrectEnable */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, /* Gains */ - {0xa0, 0x40, 0x0116}, /* RGain */ - {0xa0, 0x40, 0x0117}, /* GGain */ - {0xa0, 0x40, 0x0118}, /* BGain */ + {0xa0, 0x40, ZC3XX_R116_RGAIN}, + {0xa0, 0x40, ZC3XX_R117_GGAIN}, + {0xa0, 0x40, ZC3XX_R118_BGAIN}, - {0xa0, 0x00, 0x0007}, /* AutoCorrectEnable */ - {0xa0, 0xff, 0x0018}, /* Frame adjust */ + {0xa0, 0x00, 0x0007}, /* AutoCorrectEnable */ + {0xa0, 0xff, ZC3XX_R018_FRAMELOST}, /* Frame adjust */ {} }; static const struct usb_action pas106b_50HZ[] = { - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x06, 0x0191}, /* 01,91,06,cc */ - {0xa0, 0x54, 0x0192}, /* 01,92,54,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x87, 0x0197}, /* 01,97,87,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x30, 0x018f}, /* 01,8f,30,cc */ - {0xaa, 0x03, 0x0021}, /* 00,03,21,aa */ - {0xaa, 0x04, 0x000c}, /* 00,04,0c,aa */ - {0xaa, 0x05, 0x0002}, /* 00,05,02,aa */ - {0xaa, 0x07, 0x001c}, /* 00,07,1c,aa */ - {0xa0, 0x04, 0x01a9}, /* 01,a9,04,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x06, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,06,cc */ + {0xa0, 0x54, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,54,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x87, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,87,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x30, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,30,cc */ + {0xaa, 0x03, 0x0021}, /* 00,03,21,aa */ + {0xaa, 0x04, 0x000c}, /* 00,04,0c,aa */ + {0xaa, 0x05, 0x0002}, /* 00,05,02,aa */ + {0xaa, 0x07, 0x001c}, /* 00,07,1c,aa */ + {0xa0, 0x04, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,04,cc */ {} }; static const struct usb_action pas106b_60HZ[] = { - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x06, 0x0191}, /* 01,91,06,cc */ - {0xa0, 0x2e, 0x0192}, /* 01,92,2e,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x71, 0x0197}, /* 01,97,71,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x30, 0x018f}, /* 01,8f,30,cc */ - {0xaa, 0x03, 0x001c}, /* 00,03,1c,aa */ - {0xaa, 0x04, 0x0004}, /* 00,04,04,aa */ - {0xaa, 0x05, 0x0001}, /* 00,05,01,aa */ - {0xaa, 0x07, 0x00c4}, /* 00,07,c4,aa */ - {0xa0, 0x04, 0x01a9}, /* 01,a9,04,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x06, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,06,cc */ + {0xa0, 0x2e, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,2e,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x71, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,71,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x30, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,30,cc */ + {0xaa, 0x03, 0x001c}, /* 00,03,1c,aa */ + {0xaa, 0x04, 0x0004}, /* 00,04,04,aa */ + {0xaa, 0x05, 0x0001}, /* 00,05,01,aa */ + {0xaa, 0x07, 0x00c4}, /* 00,07,c4,aa */ + {0xa0, 0x04, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,04,cc */ {} }; static const struct usb_action pas106b_NoFliker[] = { - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x06, 0x0191}, /* 01,91,06,cc */ - {0xa0, 0x50, 0x0192}, /* 01,92,50,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x10, 0x0197}, /* 01,97,10,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xaa, 0x03, 0x0013}, /* 00,03,13,aa */ - {0xaa, 0x04, 0x0000}, /* 00,04,00,aa */ - {0xaa, 0x05, 0x0001}, /* 00,05,01,aa */ - {0xaa, 0x07, 0x0030}, /* 00,07,30,aa */ - {0xa0, 0x00, 0x01a9}, /* 01,a9,00,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x06, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,06,cc */ + {0xa0, 0x50, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,50,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x10, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,10,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xaa, 0x03, 0x0013}, /* 00,03,13,aa */ + {0xaa, 0x04, 0x0000}, /* 00,04,00,aa */ + {0xaa, 0x05, 0x0001}, /* 00,05,01,aa */ + {0xaa, 0x07, 0x0030}, /* 00,07,30,aa */ + {0xa0, 0x00, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,00,cc */ {} }; static const struct usb_action pb03303x_Initial[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x0a, 0x0010}, - {0xa0, 0x10, 0x0002}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0xdc, 0x008b}, /* 8b -> dc */ - {0xa0, 0x01, 0x0001}, - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0xdc, 0x008b}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x0a, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0xdc, ZC3XX_R08B_I2CDEVICEADDR}, /* 8b -> dc */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0xdc, ZC3XX_R08B_I2CDEVICEADDR}, {0xaa, 0x01, 0x0001}, {0xaa, 0x06, 0x0000}, {0xaa, 0x08, 0x0483}, @@ -4418,20 +4429,20 @@ static const struct usb_action pb03303x_Initial[] = { {0xaa, 0x2c, 0x0030}, {0xaa, 0x2d, 0x0030}, {0xaa, 0x2e, 0x0028}, - {0xa0, 0x10, 0x0087}, - {0xa0, 0x37, 0x0101}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, + {0xa0, 0x10, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x37, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, {0xa0, 0x00, 0x01ad}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, - {0xa0, 0x60, 0x01a8}, - {0xa0, 0x78, 0x018d}, - {0xa0, 0x61, 0x0116}, - {0xa0, 0x65, 0x0118}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, + {0xa0, 0x78, ZC3XX_R18D_YTARGET}, + {0xa0, 0x61, ZC3XX_R116_RGAIN}, + {0xa0, 0x65, ZC3XX_R118_BGAIN}, {0xa1, 0x01, 0x0002}, {0xa0, 0x09, 0x01ad}, @@ -4439,112 +4450,112 @@ static const struct usb_action pb03303x_Initial[] = { {0xa0, 0x0d, 0x003a}, {0xa0, 0x02, 0x003b}, {0xa0, 0x00, 0x0038}, - {0xa0, 0x50, 0x010a}, /* matrix */ - {0xa0, 0xf8, 0x010b}, - {0xa0, 0xf8, 0x010c}, - {0xa0, 0xf8, 0x010d}, - {0xa0, 0x50, 0x010e}, - {0xa0, 0xf8, 0x010f}, - {0xa0, 0xf8, 0x0110}, - {0xa0, 0xf8, 0x0111}, - {0xa0, 0x50, 0x0112}, + {0xa0, 0x50, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf8, ZC3XX_R10B_RGB01}, + {0xa0, 0xf8, ZC3XX_R10C_RGB02}, + {0xa0, 0xf8, ZC3XX_R10D_RGB10}, + {0xa0, 0x50, ZC3XX_R10E_RGB11}, + {0xa0, 0xf8, ZC3XX_R10F_RGB12}, + {0xa0, 0xf8, ZC3XX_R110_RGB20}, + {0xa0, 0xf8, ZC3XX_R111_RGB21}, + {0xa0, 0x50, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - {0xa0, 0x13, 0x0120}, /* gamma 4 */ - {0xa0, 0x38, 0x0121}, - {0xa0, 0x59, 0x0122}, - {0xa0, 0x79, 0x0123}, - {0xa0, 0x92, 0x0124}, - {0xa0, 0xa7, 0x0125}, - {0xa0, 0xb9, 0x0126}, - {0xa0, 0xc8, 0x0127}, - {0xa0, 0xd4, 0x0128}, - {0xa0, 0xdf, 0x0129}, - {0xa0, 0xe7, 0x012a}, - {0xa0, 0xee, 0x012b}, - {0xa0, 0xf4, 0x012c}, - {0xa0, 0xf9, 0x012d}, - {0xa0, 0xfc, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x26, 0x0130}, - {0xa0, 0x22, 0x0131}, - {0xa0, 0x20, 0x0132}, - {0xa0, 0x1c, 0x0133}, - {0xa0, 0x16, 0x0134}, - {0xa0, 0x13, 0x0135}, - {0xa0, 0x10, 0x0136}, - {0xa0, 0x0d, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x06, 0x013b}, - {0xa0, 0x05, 0x013c}, - {0xa0, 0x04, 0x013d}, - {0xa0, 0x03, 0x013e}, - {0xa0, 0x02, 0x013f}, - {0xa0, 0x50, 0x010a}, /* matrix */ - {0xa0, 0xf8, 0x010b}, - {0xa0, 0xf8, 0x010c}, - {0xa0, 0xf8, 0x010d}, - {0xa0, 0x50, 0x010e}, - {0xa0, 0xf8, 0x010f}, - {0xa0, 0xf8, 0x0110}, - {0xa0, 0xf8, 0x0111}, - {0xa0, 0x50, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x13, ZC3XX_R120_GAMMA00}, /* gamma 4 */ + {0xa0, 0x38, ZC3XX_R121_GAMMA01}, + {0xa0, 0x59, ZC3XX_R122_GAMMA02}, + {0xa0, 0x79, ZC3XX_R123_GAMMA03}, + {0xa0, 0x92, ZC3XX_R124_GAMMA04}, + {0xa0, 0xa7, ZC3XX_R125_GAMMA05}, + {0xa0, 0xb9, ZC3XX_R126_GAMMA06}, + {0xa0, 0xc8, ZC3XX_R127_GAMMA07}, + {0xa0, 0xd4, ZC3XX_R128_GAMMA08}, + {0xa0, 0xdf, ZC3XX_R129_GAMMA09}, + {0xa0, 0xe7, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xee, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xf4, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xf9, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xfc, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x26, ZC3XX_R130_GAMMA10}, + {0xa0, 0x22, ZC3XX_R131_GAMMA11}, + {0xa0, 0x20, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1c, ZC3XX_R133_GAMMA13}, + {0xa0, 0x16, ZC3XX_R134_GAMMA14}, + {0xa0, 0x13, ZC3XX_R135_GAMMA15}, + {0xa0, 0x10, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0d, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x06, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x05, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x04, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x03, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x02, ZC3XX_R13F_GAMMA1F}, + {0xa0, 0x50, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf8, ZC3XX_R10B_RGB01}, + {0xa0, 0xf8, ZC3XX_R10C_RGB02}, + {0xa0, 0xf8, ZC3XX_R10D_RGB10}, + {0xa0, 0x50, ZC3XX_R10E_RGB11}, + {0xa0, 0xf8, ZC3XX_R10F_RGB12}, + {0xa0, 0xf8, ZC3XX_R110_RGB20}, + {0xa0, 0xf8, ZC3XX_R111_RGB21}, + {0xa0, 0x50, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0x05, 0x0009}, {0xaa, 0x09, 0x0134}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x07, 0x0191}, - {0xa0, 0xec, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x9c, 0x0197}, - {0xa0, 0x0e, 0x018c}, - {0xa0, 0x1c, 0x018f}, - {0xa0, 0x14, 0x01a9}, - {0xa0, 0x24, 0x01aa}, - {0xa0, 0xd7, 0x001d}, - {0xa0, 0xf4, 0x001e}, - {0xa0, 0xf9, 0x001f}, - {0xa0, 0xff, 0x0020}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0xec, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x9c, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x0e, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x1c, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x14, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0xd7, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0xf4, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xf9, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa0, 0x09, 0x01ad}, {0xa0, 0x15, 0x01ae}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {} }; static const struct usb_action pb03303x_InitialScale[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x0a, 0x0010}, - {0xa0, 0x00, 0x0002}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0xdc, 0x008b}, /* 8b -> dc */ - {0xa0, 0x01, 0x0001}, - {0xa0, 0x03, 0x0012}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0xdc, 0x008b}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x0a, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0xdc, ZC3XX_R08B_I2CDEVICEADDR}, /* 8b -> dc */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0xdc, ZC3XX_R08B_I2CDEVICEADDR}, {0xaa, 0x01, 0x0001}, {0xaa, 0x06, 0x0000}, {0xaa, 0x08, 0x0483}, @@ -4564,20 +4575,20 @@ static const struct usb_action pb03303x_InitialScale[] = { {0xaa, 0x2c, 0x0030}, {0xaa, 0x2d, 0x0030}, {0xaa, 0x2e, 0x0028}, - {0xa0, 0x10, 0x0087}, - {0xa0, 0x37, 0x0101}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, + {0xa0, 0x10, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x37, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, {0xa0, 0x00, 0x01ad}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, - {0xa0, 0x60, 0x01a8}, - {0xa0, 0x78, 0x018d}, - {0xa0, 0x61, 0x0116}, - {0xa0, 0x65, 0x0118}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, + {0xa0, 0x78, ZC3XX_R18D_YTARGET}, + {0xa0, 0x61, ZC3XX_R116_RGAIN}, + {0xa0, 0x65, ZC3XX_R118_BGAIN}, {0xa1, 0x01, 0x0002}, @@ -4587,113 +4598,113 @@ static const struct usb_action pb03303x_InitialScale[] = { {0xa0, 0x0d, 0x003a}, {0xa0, 0x02, 0x003b}, {0xa0, 0x00, 0x0038}, - {0xa0, 0x50, 0x010a}, /* matrix */ - {0xa0, 0xf8, 0x010b}, - {0xa0, 0xf8, 0x010c}, - {0xa0, 0xf8, 0x010d}, - {0xa0, 0x50, 0x010e}, - {0xa0, 0xf8, 0x010f}, - {0xa0, 0xf8, 0x0110}, - {0xa0, 0xf8, 0x0111}, - {0xa0, 0x50, 0x0112}, + {0xa0, 0x50, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf8, ZC3XX_R10B_RGB01}, + {0xa0, 0xf8, ZC3XX_R10C_RGB02}, + {0xa0, 0xf8, ZC3XX_R10D_RGB10}, + {0xa0, 0x50, ZC3XX_R10E_RGB11}, + {0xa0, 0xf8, ZC3XX_R10F_RGB12}, + {0xa0, 0xf8, ZC3XX_R110_RGB20}, + {0xa0, 0xf8, ZC3XX_R111_RGB21}, + {0xa0, 0x50, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - - {0xa0, 0x13, 0x0120}, /* gamma 4 */ - {0xa0, 0x38, 0x0121}, - {0xa0, 0x59, 0x0122}, - {0xa0, 0x79, 0x0123}, - {0xa0, 0x92, 0x0124}, - {0xa0, 0xa7, 0x0125}, - {0xa0, 0xb9, 0x0126}, - {0xa0, 0xc8, 0x0127}, - {0xa0, 0xd4, 0x0128}, - {0xa0, 0xdf, 0x0129}, - {0xa0, 0xe7, 0x012a}, - {0xa0, 0xee, 0x012b}, - {0xa0, 0xf4, 0x012c}, - {0xa0, 0xf9, 0x012d}, - {0xa0, 0xfc, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x26, 0x0130}, - {0xa0, 0x22, 0x0131}, - {0xa0, 0x20, 0x0132}, - {0xa0, 0x1c, 0x0133}, - {0xa0, 0x16, 0x0134}, - {0xa0, 0x13, 0x0135}, - {0xa0, 0x10, 0x0136}, - {0xa0, 0x0d, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x06, 0x013b}, - {0xa0, 0x05, 0x013c}, - {0xa0, 0x04, 0x013d}, - {0xa0, 0x03, 0x013e}, - {0xa0, 0x02, 0x013f}, - {0xa0, 0x50, 0x010a}, /* matrix */ - {0xa0, 0xf8, 0x010b}, - {0xa0, 0xf8, 0x010c}, - {0xa0, 0xf8, 0x010d}, - {0xa0, 0x50, 0x010e}, - {0xa0, 0xf8, 0x010f}, - {0xa0, 0xf8, 0x0110}, - {0xa0, 0xf8, 0x0111}, - {0xa0, 0x50, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + + {0xa0, 0x13, ZC3XX_R120_GAMMA00}, /* gamma 4 */ + {0xa0, 0x38, ZC3XX_R121_GAMMA01}, + {0xa0, 0x59, ZC3XX_R122_GAMMA02}, + {0xa0, 0x79, ZC3XX_R123_GAMMA03}, + {0xa0, 0x92, ZC3XX_R124_GAMMA04}, + {0xa0, 0xa7, ZC3XX_R125_GAMMA05}, + {0xa0, 0xb9, ZC3XX_R126_GAMMA06}, + {0xa0, 0xc8, ZC3XX_R127_GAMMA07}, + {0xa0, 0xd4, ZC3XX_R128_GAMMA08}, + {0xa0, 0xdf, ZC3XX_R129_GAMMA09}, + {0xa0, 0xe7, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xee, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xf4, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xf9, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xfc, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x26, ZC3XX_R130_GAMMA10}, + {0xa0, 0x22, ZC3XX_R131_GAMMA11}, + {0xa0, 0x20, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1c, ZC3XX_R133_GAMMA13}, + {0xa0, 0x16, ZC3XX_R134_GAMMA14}, + {0xa0, 0x13, ZC3XX_R135_GAMMA15}, + {0xa0, 0x10, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0d, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x06, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x05, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x04, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x03, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x02, ZC3XX_R13F_GAMMA1F}, + {0xa0, 0x50, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf8, ZC3XX_R10B_RGB01}, + {0xa0, 0xf8, ZC3XX_R10C_RGB02}, + {0xa0, 0xf8, ZC3XX_R10D_RGB10}, + {0xa0, 0x50, ZC3XX_R10E_RGB11}, + {0xa0, 0xf8, ZC3XX_R10F_RGB12}, + {0xa0, 0xf8, ZC3XX_R110_RGB20}, + {0xa0, 0xf8, ZC3XX_R111_RGB21}, + {0xa0, 0x50, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0x05, 0x0009}, {0xaa, 0x09, 0x0134}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x07, 0x0191}, - {0xa0, 0xec, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x9c, 0x0197}, - {0xa0, 0x0e, 0x018c}, - {0xa0, 0x1c, 0x018f}, - {0xa0, 0x14, 0x01a9}, - {0xa0, 0x24, 0x01aa}, - {0xa0, 0xd7, 0x001d}, - {0xa0, 0xf4, 0x001e}, - {0xa0, 0xf9, 0x001f}, - {0xa0, 0xff, 0x0020}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0xec, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x9c, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x0e, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x1c, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x14, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0xd7, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0xf4, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xf9, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa0, 0x09, 0x01ad}, {0xa0, 0x15, 0x01ae}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {} }; static const struct usb_action pb0330xx_Initial[] = { {0xa1, 0x01, 0x0008}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x01, 0x0000}, - {0xa0, 0x03, 0x0008}, /* 00 */ - {0xa0, 0x0a, 0x0010}, - {0xa0, 0x10, 0x0002}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x07, 0x0012}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0x05, 0x0012}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00 */ + {0xa0, 0x0a, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x07, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, {0xaa, 0x01, 0x0006}, {0xaa, 0x02, 0x0011}, {0xaa, 0x03, 0x01e7}, @@ -4710,79 +4721,79 @@ static const struct usb_action pb0330xx_Initial[] = { {0xaa, 0x40, 0x01e0}, {0xaa, 0x58, 0x0078}, {0xaa, 0x62, 0x0411}, - {0xa0, 0x10, 0x0087}, - {0xa0, 0x37, 0x0101}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, + {0xa0, 0x10, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x37, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, {0xa0, 0x00, 0x01ad}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, - {0xa0, 0x60, 0x01a8}, - {0xa0, 0x6c, 0x018d}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, + {0xa0, 0x6c, ZC3XX_R18D_YTARGET}, {0xa1, 0x01, 0x0002}, {0xa0, 0x09, 0x01ad}, {0xa0, 0x15, 0x01ae}, - {0xa0, 0x00, 0x0092}, - {0xa0, 0x02, 0x0090}, + {0xa0, 0x00, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R090_I2CCOMMAND}, {0xa1, 0x01, 0x0091}, {0xa1, 0x01, 0x0095}, {0xa1, 0x01, 0x0096}, - {0xa0, 0x50, 0x010a}, /* matrix */ - {0xa0, 0xf8, 0x010b}, - {0xa0, 0xf8, 0x010c}, - {0xa0, 0xf8, 0x010d}, - {0xa0, 0x50, 0x010e}, - {0xa0, 0xf8, 0x010f}, - {0xa0, 0xf8, 0x0110}, - {0xa0, 0xf8, 0x0111}, - {0xa0, 0x50, 0x0112}, + {0xa0, 0x50, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf8, ZC3XX_R10B_RGB01}, + {0xa0, 0xf8, ZC3XX_R10C_RGB02}, + {0xa0, 0xf8, ZC3XX_R10D_RGB10}, + {0xa0, 0x50, ZC3XX_R10E_RGB11}, + {0xa0, 0xf8, ZC3XX_R10F_RGB12}, + {0xa0, 0xf8, ZC3XX_R110_RGB20}, + {0xa0, 0xf8, ZC3XX_R111_RGB21}, + {0xa0, 0x50, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - - {0xa0, 0x50, 0x010a}, /* matrix */ - {0xa0, 0xf8, 0x010b}, - {0xa0, 0xf8, 0x010c}, - {0xa0, 0xf8, 0x010d}, - {0xa0, 0x50, 0x010e}, - {0xa0, 0xf8, 0x010f}, - {0xa0, 0xf8, 0x0110}, - {0xa0, 0xf8, 0x0111}, - {0xa0, 0x50, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + + {0xa0, 0x50, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf8, ZC3XX_R10B_RGB01}, + {0xa0, 0xf8, ZC3XX_R10C_RGB02}, + {0xa0, 0xf8, ZC3XX_R10D_RGB10}, + {0xa0, 0x50, ZC3XX_R10E_RGB11}, + {0xa0, 0xf8, ZC3XX_R10F_RGB12}, + {0xa0, 0xf8, ZC3XX_R110_RGB20}, + {0xa0, 0xf8, ZC3XX_R111_RGB21}, + {0xa0, 0x50, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0x05, 0x0066}, {0xaa, 0x09, 0x02b2}, {0xaa, 0x10, 0x0002}, - {0xa0, 0x60, 0x011d}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x07, 0x0191}, - {0xa0, 0x8c, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x8a, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x14, 0x01a9}, - {0xa0, 0x24, 0x01aa}, - {0xa0, 0xd7, 0x001d}, - {0xa0, 0xf0, 0x001e}, - {0xa0, 0xf8, 0x001f}, - {0xa0, 0xff, 0x0020}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0x8c, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x8a, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x14, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0xd7, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0xf0, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xf8, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, {0xa0, 0x09, 0x01ad}, {0xa0, 0x15, 0x01ae}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0008}, {0xa1, 0x01, 0x0007}, /* {0xa0, 0x30, 0x0007}, */ @@ -4793,22 +4804,22 @@ static const struct usb_action pb0330xx_Initial[] = { static const struct usb_action pb0330xx_InitialScale[] = { {0xa1, 0x01, 0x0008}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x01, 0x0000}, - {0xa0, 0x03, 0x0008}, /* 00 */ - {0xa0, 0x0a, 0x0010}, - {0xa0, 0x00, 0x0002}, /* 10 */ - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x07, 0x0012}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0x05, 0x0012}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00 */ + {0xa0, 0x0a, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, /* 10 */ + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x07, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, {0xaa, 0x01, 0x0006}, {0xaa, 0x02, 0x0011}, {0xaa, 0x03, 0x01e7}, @@ -4825,78 +4836,78 @@ static const struct usb_action pb0330xx_InitialScale[] = { {0xaa, 0x40, 0x01e0}, {0xaa, 0x58, 0x0078}, {0xaa, 0x62, 0x0411}, - {0xa0, 0x10, 0x0087}, - {0xa0, 0x37, 0x0101}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, + {0xa0, 0x10, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0x37, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, {0xa0, 0x00, 0x01ad}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, - {0xa0, 0x60, 0x01a8}, - {0xa0, 0x6c, 0x018d}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, + {0xa0, 0x6c, ZC3XX_R18D_YTARGET}, {0xa1, 0x01, 0x0002}, {0xa0, 0x09, 0x01ad}, {0xa0, 0x15, 0x01ae}, - {0xa0, 0x00, 0x0092}, - {0xa0, 0x02, 0x0090}, + {0xa0, 0x00, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R090_I2CCOMMAND}, {0xa1, 0x01, 0x0091}, {0xa1, 0x01, 0x0095}, {0xa1, 0x01, 0x0096}, - {0xa0, 0x50, 0x010a}, /* matrix */ - {0xa0, 0xf8, 0x010b}, - {0xa0, 0xf8, 0x010c}, - {0xa0, 0xf8, 0x010d}, - {0xa0, 0x50, 0x010e}, - {0xa0, 0xf8, 0x010f}, - {0xa0, 0xf8, 0x0110}, - {0xa0, 0xf8, 0x0111}, - {0xa0, 0x50, 0x0112}, + {0xa0, 0x50, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf8, ZC3XX_R10B_RGB01}, + {0xa0, 0xf8, ZC3XX_R10C_RGB02}, + {0xa0, 0xf8, ZC3XX_R10D_RGB10}, + {0xa0, 0x50, ZC3XX_R10E_RGB11}, + {0xa0, 0xf8, ZC3XX_R10F_RGB12}, + {0xa0, 0xf8, ZC3XX_R110_RGB20}, + {0xa0, 0xf8, ZC3XX_R111_RGB21}, + {0xa0, 0x50, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - - {0xa0, 0x50, 0x010a}, /* matrix */ - {0xa0, 0xf8, 0x010b}, - {0xa0, 0xf8, 0x010c}, - {0xa0, 0xf8, 0x010d}, - {0xa0, 0x50, 0x010e}, - {0xa0, 0xf8, 0x010f}, - {0xa0, 0xf8, 0x0110}, - {0xa0, 0xf8, 0x0111}, - {0xa0, 0x50, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + + {0xa0, 0x50, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf8, ZC3XX_R10B_RGB01}, + {0xa0, 0xf8, ZC3XX_R10C_RGB02}, + {0xa0, 0xf8, ZC3XX_R10D_RGB10}, + {0xa0, 0x50, ZC3XX_R10E_RGB11}, + {0xa0, 0xf8, ZC3XX_R10F_RGB12}, + {0xa0, 0xf8, ZC3XX_R110_RGB20}, + {0xa0, 0xf8, ZC3XX_R111_RGB21}, + {0xa0, 0x50, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0x05, 0x0066}, {0xaa, 0x09, 0x02b2}, {0xaa, 0x10, 0x0002}, - {0xa0, 0x60, 0x011d}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x07, 0x0191}, - {0xa0, 0x8c, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x8a, 0x0197}, - {0xa0, 0x10, 0x018c}, - {0xa0, 0x20, 0x018f}, - {0xa0, 0x14, 0x01a9}, - {0xa0, 0x24, 0x01aa}, - {0xa0, 0xd7, 0x001d}, - {0xa0, 0xf0, 0x001e}, - {0xa0, 0xf8, 0x001f}, - {0xa0, 0xff, 0x0020}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0x8c, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x8a, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x14, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0xd7, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0xf0, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xf8, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, {0xa0, 0x09, 0x01ad}, {0xa0, 0x15, 0x01ae}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0008}, {0xa1, 0x01, 0x0007}, /* {0xa0, 0x30, 0x0007}, */ @@ -4904,136 +4915,136 @@ static const struct usb_action pb0330xx_InitialScale[] = { {} }; static const struct usb_action pb0330_50HZ[] = { - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x07, 0x0191}, /* 01,91,07,cc */ - {0xa0, 0xee, 0x0192}, /* 01,92,ee,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x46, 0x0197}, /* 01,97,46,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x0c, 0x01a9}, /* 01,a9,0c,cc */ - {0xa0, 0x26, 0x01aa}, /* 01,aa,26,cc */ - {0xa0, 0x68, 0x001d}, /* 00,1d,68,cc */ - {0xa0, 0x90, 0x001e}, /* 00,1e,90,cc */ - {0xa0, 0xc8, 0x001f}, /* 00,1f,c8,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,07,cc */ + {0xa0, 0xee, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,ee,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x46, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,46,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,0c,cc */ + {0xa0, 0x26, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,26,cc */ + {0xa0, 0x68, ZC3XX_R01D_HSYNC_0}, /* 00,1d,68,cc */ + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, /* 00,1e,90,cc */ + {0xa0, 0xc8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,c8,cc */ {} }; static const struct usb_action pb0330_50HZScale[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x07, 0x0191}, /* 01,91,07,cc */ - {0xa0, 0xa0, 0x0192}, /* 01,92,a0,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x7a, 0x0197}, /* 01,97,7a,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x0c, 0x01a9}, /* 01,a9,0c,cc */ - {0xa0, 0x26, 0x01aa}, /* 01,aa,26,cc */ - {0xa0, 0xe5, 0x001d}, /* 00,1d,e5,cc */ - {0xa0, 0xf0, 0x001e}, /* 00,1e,f0,cc */ - {0xa0, 0xf8, 0x001f}, /* 00,1f,f8,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,07,cc */ + {0xa0, 0xa0, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,a0,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x7a, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,7a,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,0c,cc */ + {0xa0, 0x26, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,26,cc */ + {0xa0, 0xe5, ZC3XX_R01D_HSYNC_0}, /* 00,1d,e5,cc */ + {0xa0, 0xf0, ZC3XX_R01E_HSYNC_1}, /* 00,1e,f0,cc */ + {0xa0, 0xf8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,f8,cc */ {} }; static const struct usb_action pb0330_60HZ[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x07, 0x0191}, /* 01,91,07,cc */ - {0xa0, 0xdd, 0x0192}, /* 01,92,dd,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x3d, 0x0197}, /* 01,97,3d,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x0c, 0x01a9}, /* 01,a9,0c,cc */ - {0xa0, 0x26, 0x01aa}, /* 01,aa,26,cc */ - {0xa0, 0x43, 0x001d}, /* 00,1d,43,cc */ - {0xa0, 0x50, 0x001e}, /* 00,1e,50,cc */ - {0xa0, 0x90, 0x001f}, /* 00,1f,90,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,07,cc */ + {0xa0, 0xdd, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,dd,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x3d, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,3d,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,0c,cc */ + {0xa0, 0x26, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,26,cc */ + {0xa0, 0x43, ZC3XX_R01D_HSYNC_0}, /* 00,1d,43,cc */ + {0xa0, 0x50, ZC3XX_R01E_HSYNC_1}, /* 00,1e,50,cc */ + {0xa0, 0x90, ZC3XX_R01F_HSYNC_2}, /* 00,1f,90,cc */ {} }; static const struct usb_action pb0330_60HZScale[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x07, 0x0191}, /* 01,91,07,cc */ - {0xa0, 0xa0, 0x0192}, /* 01,92,a0,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x7a, 0x0197}, /* 01,97,7a,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x0c, 0x01a9}, /* 01,a9,0c,cc */ - {0xa0, 0x26, 0x01aa}, /* 01,aa,26,cc */ - {0xa0, 0x41, 0x001d}, /* 00,1d,41,cc */ - {0xa0, 0x50, 0x001e}, /* 00,1e,50,cc */ - {0xa0, 0x90, 0x001f}, /* 00,1f,90,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,07,cc */ + {0xa0, 0xa0, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,a0,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x7a, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,7a,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,0c,cc */ + {0xa0, 0x26, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,26,cc */ + {0xa0, 0x41, ZC3XX_R01D_HSYNC_0}, /* 00,1d,41,cc */ + {0xa0, 0x50, ZC3XX_R01E_HSYNC_1}, /* 00,1e,50,cc */ + {0xa0, 0x90, ZC3XX_R01F_HSYNC_2}, /* 00,1f,90,cc */ {} }; static const struct usb_action pb0330_NoFliker[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x07, 0x0191}, /* 01,91,07,cc */ - {0xa0, 0xf0, 0x0192}, /* 01,92,f0,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x10, 0x0197}, /* 01,97,10,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x00, 0x01a9}, /* 01,a9,00,cc */ - {0xa0, 0x00, 0x01aa}, /* 01,aa,00,cc */ - {0xa0, 0x09, 0x001d}, /* 00,1d,09,cc */ - {0xa0, 0x40, 0x001e}, /* 00,1e,40,cc */ - {0xa0, 0x90, 0x001f}, /* 00,1f,90,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,07,cc */ + {0xa0, 0xf0, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,f0,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x10, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,10,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x00, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,00,cc */ + {0xa0, 0x00, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,00,cc */ + {0xa0, 0x09, ZC3XX_R01D_HSYNC_0}, /* 00,1d,09,cc */ + {0xa0, 0x40, ZC3XX_R01E_HSYNC_1}, /* 00,1e,40,cc */ + {0xa0, 0x90, ZC3XX_R01F_HSYNC_2}, /* 00,1f,90,cc */ {} }; static const struct usb_action pb0330_NoFlikerScale[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x07, 0x0191}, /* 01,91,07,cc */ - {0xa0, 0xf0, 0x0192}, /* 01,92,f0,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x10, 0x0197}, /* 01,97,10,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x00, 0x01a9}, /* 01,a9,00,cc */ - {0xa0, 0x00, 0x01aa}, /* 01,aa,00,cc */ - {0xa0, 0x09, 0x001d}, /* 00,1d,09,cc */ - {0xa0, 0x40, 0x001e}, /* 00,1e,40,cc */ - {0xa0, 0x90, 0x001f}, /* 00,1f,90,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,07,cc */ + {0xa0, 0xf0, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,f0,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x10, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,10,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x00, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,00,cc */ + {0xa0, 0x00, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,00,cc */ + {0xa0, 0x09, ZC3XX_R01D_HSYNC_0}, /* 00,1d,09,cc */ + {0xa0, 0x40, ZC3XX_R01E_HSYNC_1}, /* 00,1e,40,cc */ + {0xa0, 0x90, ZC3XX_R01F_HSYNC_2}, /* 00,1f,90,cc */ {} }; /* from oem9.inf - HKR,%PO2030%,Initial - 640x480 - (close to CS2102) */ static const struct usb_action PO2030_mode0[] = { - {0xa0, 0x01, 0x0000}, /* 00,00,01,cc */ - {0xa0, 0x04, 0x0002}, /* 00,02,04,cc */ - {0xa0, 0x01, 0x0010}, /* 00,10,01,cc */ - {0xa0, 0x01, 0x0001}, /* 00,01,01,cc */ - {0xa0, 0x04, 0x0080}, /* 00,80,04,cc */ - {0xa0, 0x05, 0x0081}, /* 00,81,05,cc */ - {0xa0, 0x16, 0x0083}, /* 00,83,16,cc */ - {0xa0, 0x18, 0x0085}, /* 00,85,18,cc */ - {0xa0, 0x1a, 0x0086}, /* 00,86,1a,cc */ - {0xa0, 0x1b, 0x0087}, /* 00,87,1b,cc */ - {0xa0, 0x1c, 0x0088}, /* 00,88,1c,cc */ - {0xa0, 0xee, 0x008b}, /* 00,8b,ee,cc */ - {0xa0, 0x03, 0x0008}, /* 00,08,03,cc */ - {0xa0, 0x03, 0x0012}, /* 00,12,03,cc */ - {0xa0, 0x01, 0x0012}, /* 00,12,01,cc */ - {0xa0, 0x02, 0x0003}, /* 00,03,02,cc */ - {0xa0, 0x80, 0x0004}, /* 00,04,80,cc */ - {0xa0, 0x01, 0x0005}, /* 00,05,01,cc */ - {0xa0, 0xe0, 0x0006}, /* 00,06,e0,cc */ - {0xa0, 0x42, 0x0180}, /* 01,80,42,cc */ - {0xaa, 0x8d, 0x0008}, /* 00,8d,08,aa */ - {0xa0, 0x00, 0x0098}, /* 00,98,00,cc */ - {0xa0, 0x00, 0x009a}, /* 00,9a,00,cc */ - {0xa0, 0x00, 0x011a}, /* 01,1a,00,cc */ - {0xa0, 0x00, 0x011c}, /* 01,1c,00,cc */ - {0xa0, 0xe6, 0x009c}, /* 00,9c,e6,cc */ - {0xa0, 0x86, 0x009e}, /* 00,9e,86,cc */ + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, /* 00,00,01,cc */ + {0xa0, 0x04, ZC3XX_R002_CLOCKSELECT}, /* 00,02,04,cc */ + {0xa0, 0x01, ZC3XX_R010_CMOSSENSORSELECT}, /* 00,10,01,cc */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, /* 00,01,01,cc */ + {0xa0, 0x04, ZC3XX_R080_HBLANKHIGH}, /* 00,80,04,cc */ + {0xa0, 0x05, ZC3XX_R081_HBLANKLOW}, /* 00,81,05,cc */ + {0xa0, 0x16, ZC3XX_R083_RGAINADDR}, /* 00,83,16,cc */ + {0xa0, 0x18, ZC3XX_R085_BGAINADDR}, /* 00,85,18,cc */ + {0xa0, 0x1a, ZC3XX_R086_EXPTIMEHIGH}, /* 00,86,1a,cc */ + {0xa0, 0x1b, ZC3XX_R087_EXPTIMEMID}, /* 00,87,1b,cc */ + {0xa0, 0x1c, ZC3XX_R088_EXPTIMELOW}, /* 00,88,1c,cc */ + {0xa0, 0xee, ZC3XX_R08B_I2CDEVICEADDR}, /* 00,8b,ee,cc */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00,08,03,cc */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,03,cc */ + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,01,cc */ + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, /* 00,03,02,cc */ + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, /* 00,04,80,cc */ + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, /* 00,05,01,cc */ + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, /* 00,06,e0,cc */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,42,cc */ + {0xaa, 0x8d, 0x0008}, /* 00,8d,08,aa */ + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, /* 00,98,00,cc */ + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, /* 00,9a,00,cc */ + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, /* 01,1a,00,cc */ + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, /* 01,1c,00,cc */ + {0xa0, 0xe6, ZC3XX_R09C_WINHEIGHTLOW}, /* 00,9c,e6,cc */ + {0xa0, 0x86, ZC3XX_R09E_WINWIDTHLOW}, /* 00,9e,86,cc */ {0xaa, 0x09, 0x00ce}, /* 00,09,ce,aa */ {0xaa, 0x0b, 0x0005}, /* 00,0b,05,aa */ {0xaa, 0x0d, 0x0054}, /* 00,0d,54,aa */ @@ -5068,49 +5079,49 @@ static const struct usb_action PO2030_mode0[] = { {0xaa, 0x6b, 0x00a0}, /* 00,6b,a0,aa */ {0xaa, 0x6c, 0x0054}, /* 00,6c,54,aa */ {0xaa, 0xd6, 0x0007}, /* 00,d6,07,aa */ - {0xa0, 0xf7, 0x0101}, /* 01,01,f7,cc */ - {0xa0, 0x05, 0x0012}, /* 00,12,05,cc */ - {0xa0, 0x0d, 0x0100}, /* 01,00,0d,cc */ - {0xa0, 0x06, 0x0189}, /* 01,89,06,cc */ + {0xa0, 0xf7, ZC3XX_R101_SENSORCORRECTION}, /* 01,01,f7,cc */ + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,05,cc */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* 01,00,0d,cc */ + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, /* 01,89,06,cc */ {0xa0, 0x00, 0x01ad}, /* 01,ad,00,cc */ - {0xa0, 0x03, 0x01c5}, /* 01,c5,03,cc */ - {0xa0, 0x13, 0x01cb}, /* 01,cb,13,cc */ - {0xa0, 0x08, 0x0250}, /* 02,50,08,cc */ - {0xa0, 0x08, 0x0301}, /* 03,01,08,cc */ - {0xa0, 0x7a, 0x0116}, /* 01,16,7a,cc */ - {0xa0, 0x4a, 0x0118}, /* 01,18,4a,cc */ + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, /* 01,c5,03,cc */ + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, /* 01,cb,13,cc */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* 02,50,08,cc */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* 03,01,08,cc */ + {0xa0, 0x7a, ZC3XX_R116_RGAIN}, /* 01,16,7a,cc */ + {0xa0, 0x4a, ZC3XX_R118_BGAIN}, /* 01,18,4a,cc */ {} }; /* from oem9.inf - HKR,%PO2030%,InitialScale - 320x240 */ static const struct usb_action PO2030_mode1[] = { - {0xa0, 0x01, 0x0000}, /* 00,00,01,cc */ - {0xa0, 0x10, 0x0002}, /* 00,02,10,cc */ - {0xa0, 0x01, 0x0010}, /* 00,10,01,cc */ - {0xa0, 0x01, 0x0001}, /* 00,01,01,cc */ - {0xa0, 0x04, 0x0080}, /* 00,80,04,cc */ - {0xa0, 0x05, 0x0081}, /* 00,81,05,cc */ - {0xa0, 0x16, 0x0083}, /* 00,83,16,cc */ - {0xa0, 0x18, 0x0085}, /* 00,85,18,cc */ - {0xa0, 0x1a, 0x0086}, /* 00,86,1a,cc */ - {0xa0, 0x1b, 0x0087}, /* 00,87,1b,cc */ - {0xa0, 0x1c, 0x0088}, /* 00,88,1c,cc */ - {0xa0, 0xee, 0x008b}, /* 00,8b,ee,cc */ - {0xa0, 0x03, 0x0008}, /* 00,08,03,cc */ - {0xa0, 0x03, 0x0012}, /* 00,12,03,cc */ - {0xa0, 0x01, 0x0012}, /* 00,12,01,cc */ - {0xa0, 0x02, 0x0003}, /* 00,03,02,cc */ - {0xa0, 0x80, 0x0004}, /* 00,04,80,cc */ - {0xa0, 0x01, 0x0005}, /* 00,05,01,cc */ - {0xa0, 0xe0, 0x0006}, /* 00,06,e0,cc */ - {0xa0, 0x42, 0x0180}, /* 01,80,42,cc */ - {0xaa, 0x8d, 0x0008}, /* 00,8d,08,aa */ - {0xa0, 0x00, 0x0098}, /* 00,98,00,cc */ - {0xa0, 0x00, 0x009a}, /* 00,9a,00,cc */ - {0xa0, 0x00, 0x011a}, /* 01,1a,00,cc */ - {0xa0, 0x00, 0x011c}, /* 01,1c,00,cc */ - {0xa0, 0xe8, 0x009c}, /* 00,9c,e8,cc */ - {0xa0, 0x88, 0x009e}, /* 00,9e,88,cc */ + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, /* 00,00,01,cc */ + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, /* 00,02,10,cc */ + {0xa0, 0x01, ZC3XX_R010_CMOSSENSORSELECT}, /* 00,10,01,cc */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, /* 00,01,01,cc */ + {0xa0, 0x04, ZC3XX_R080_HBLANKHIGH}, /* 00,80,04,cc */ + {0xa0, 0x05, ZC3XX_R081_HBLANKLOW}, /* 00,81,05,cc */ + {0xa0, 0x16, ZC3XX_R083_RGAINADDR}, /* 00,83,16,cc */ + {0xa0, 0x18, ZC3XX_R085_BGAINADDR}, /* 00,85,18,cc */ + {0xa0, 0x1a, ZC3XX_R086_EXPTIMEHIGH}, /* 00,86,1a,cc */ + {0xa0, 0x1b, ZC3XX_R087_EXPTIMEMID}, /* 00,87,1b,cc */ + {0xa0, 0x1c, ZC3XX_R088_EXPTIMELOW}, /* 00,88,1c,cc */ + {0xa0, 0xee, ZC3XX_R08B_I2CDEVICEADDR}, /* 00,8b,ee,cc */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* 00,08,03,cc */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,03,cc */ + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,01,cc */ + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, /* 00,03,02,cc */ + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, /* 00,04,80,cc */ + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, /* 00,05,01,cc */ + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, /* 00,06,e0,cc */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,42,cc */ + {0xaa, 0x8d, 0x0008}, /* 00,8d,08,aa */ + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, /* 00,98,00,cc */ + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, /* 00,9a,00,cc */ + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, /* 01,1a,00,cc */ + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, /* 01,1c,00,cc */ + {0xa0, 0xe8, ZC3XX_R09C_WINHEIGHTLOW}, /* 00,9c,e8,cc */ + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, /* 00,9e,88,cc */ {0xaa, 0x09, 0x00cc}, /* 00,09,cc,aa */ {0xaa, 0x0b, 0x0005}, /* 00,0b,05,aa */ {0xaa, 0x0d, 0x0058}, /* 00,0d,58,aa */ @@ -5145,17 +5156,17 @@ static const struct usb_action PO2030_mode1[] = { {0xaa, 0x6b, 0x00a0}, /* 00,6b,a0,aa */ {0xaa, 0x6c, 0x0054}, /* 00,6c,54,aa */ {0xaa, 0xd6, 0x0007}, /* 00,d6,07,aa */ - {0xa0, 0xf7, 0x0101}, /* 01,01,f7,cc */ - {0xa0, 0x05, 0x0012}, /* 00,12,05,cc */ - {0xa0, 0x0d, 0x0100}, /* 01,00,0d,cc */ - {0xa0, 0x06, 0x0189}, /* 01,89,06,cc */ + {0xa0, 0xf7, ZC3XX_R101_SENSORCORRECTION}, /* 01,01,f7,cc */ + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,05,cc */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* 01,00,0d,cc */ + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, /* 01,89,06,cc */ {0xa0, 0x00, 0x01ad}, /* 01,ad,00,cc */ - {0xa0, 0x03, 0x01c5}, /* 01,c5,03,cc */ - {0xa0, 0x13, 0x01cb}, /* 01,cb,13,cc */ - {0xa0, 0x08, 0x0250}, /* 02,50,08,cc */ - {0xa0, 0x08, 0x0301}, /* 03,01,08,cc */ - {0xa0, 0x7a, 0x0116}, /* 01,16,7a,cc */ - {0xa0, 0x4a, 0x0118}, /* 01,18,4a,cc */ + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, /* 01,c5,03,cc */ + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, /* 01,cb,13,cc */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* 02,50,08,cc */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* 03,01,08,cc */ + {0xa0, 0x7a, ZC3XX_R116_RGAIN}, /* 01,16,7a,cc */ + {0xa0, 0x4a, ZC3XX_R118_BGAIN}, /* 01,18,4a,cc */ {} }; @@ -5164,20 +5175,20 @@ static const struct usb_action PO2030_50HZ[] = { {0xaa, 0x1a, 0x0001}, /* 00,1a,01,aa */ {0xaa, 0x1b, 0x000a}, /* 00,1b,0a,aa */ {0xaa, 0x1c, 0x00b0}, /* 00,1c,b0,aa */ - {0xa0, 0x05, 0x0190}, /* 01,90,05,cc */ - {0xa0, 0x35, 0x0191}, /* 01,91,35,cc */ - {0xa0, 0x70, 0x0192}, /* 01,92,70,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x85, 0x0196}, /* 01,96,85,cc */ - {0xa0, 0x58, 0x0197}, /* 01,97,58,cc */ - {0xa0, 0x0c, 0x018c}, /* 01,8c,0c,cc */ - {0xa0, 0x18, 0x018f}, /* 01,8f,18,cc */ - {0xa0, 0x60, 0x01a8}, /* 01,a8,60,cc */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc */ - {0xa0, 0x22, 0x01aa}, /* 01,aa,22,cc */ - {0xa0, 0x88, 0x018d}, /* 01,8d,88,cc */ - {0xa0, 0x58, 0x011d}, /* 01,1d,58,cc */ - {0xa0, 0x42, 0x0180}, /* 01,80,42,cc */ + {0xa0, 0x05, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,05,cc */ + {0xa0, 0x35, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,35,cc */ + {0xa0, 0x70, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,70,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x85, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,85,cc */ + {0xa0, 0x58, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,58,cc */ + {0xa0, 0x0c, ZC3XX_R18C_AEFREEZE}, /* 01,8c,0c,cc */ + {0xa0, 0x18, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,18,cc */ + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, /* 01,a8,60,cc */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc */ + {0xa0, 0x22, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,22,cc */ + {0xa0, 0x88, ZC3XX_R18D_YTARGET}, /* 01,8d,88,cc */ + {0xa0, 0x58, ZC3XX_R11D_GLOBALGAIN}, /* 01,1d,58,cc */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,42,cc */ {} }; @@ -5186,25 +5197,26 @@ static const struct usb_action PO2030_60HZ[] = { {0xaa, 0x1a, 0x0000}, /* 00,1a,00,aa */ {0xaa, 0x1b, 0x00de}, /* 00,1b,de,aa */ {0xaa, 0x1c, 0x0040}, /* 00,1c,40,aa */ - {0xa0, 0x08, 0x0190}, /* 01,90,08,cc */ - {0xa0, 0xae, 0x0191}, /* 01,91,ae,cc */ - {0xa0, 0x80, 0x0192}, /* 01,92,80,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x6f, 0x0196}, /* 01,96,6f,cc */ - {0xa0, 0x20, 0x0197}, /* 01,97,20,cc */ - {0xa0, 0x0c, 0x018c}, /* 01,8c,0c,cc */ - {0xa0, 0x18, 0x018f}, /* 01,8f,18,cc */ - {0xa0, 0x60, 0x01a8}, /* 01,a8,60,cc */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc */ - {0xa0, 0x22, 0x01aa}, /* 01,aa,22,cc */ - {0xa0, 0x88, 0x018d}, /* 01,8d,88,cc */ /* win: 01,8d,80 */ - {0xa0, 0x58, 0x011d}, /* 01,1d,58,cc */ - {0xa0, 0x42, 0x0180}, /* 01,80,42,cc */ + {0xa0, 0x08, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,08,cc */ + {0xa0, 0xae, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,ae,cc */ + {0xa0, 0x80, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,80,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x6f, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,6f,cc */ + {0xa0, 0x20, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,20,cc */ + {0xa0, 0x0c, ZC3XX_R18C_AEFREEZE}, /* 01,8c,0c,cc */ + {0xa0, 0x18, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,18,cc */ + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, /* 01,a8,60,cc */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc */ + {0xa0, 0x22, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,22,cc */ + {0xa0, 0x88, ZC3XX_R18D_YTARGET}, /* 01,8d,88,cc */ + /* win: 01,8d,80 */ + {0xa0, 0x58, ZC3XX_R11D_GLOBALGAIN}, /* 01,1d,58,cc */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,42,cc */ {} }; static const struct usb_action PO2030_NoFliker[] = { - {0xa0, 0x02, 0x0180}, /* 01,80,02,cc */ + {0xa0, 0x02, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,02,cc */ {0xaa, 0x8d, 0x000d}, /* 00,8d,0d,aa */ {0xaa, 0x1a, 0x0000}, /* 00,1a,00,aa */ {0xaa, 0x1b, 0x0002}, /* 00,1b,02,aa */ @@ -5216,768 +5228,771 @@ static const struct usb_action PO2030_NoFliker[] = { /* TEST */ static const struct usb_action tas5130CK_Initial[] = { - {0xa0, 0x01, 0x0000}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, {0xa0, 0x01, 0x003b}, {0xa0, 0x0e, 0x003a}, {0xa0, 0x01, 0x0038}, {0xa0, 0x0b, 0x0039}, {0xa0, 0x00, 0x0038}, {0xa0, 0x0b, 0x0039}, - {0xa0, 0x01, 0x0000}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x0a, 0x0010}, - {0xa0, 0x10, 0x0002}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0xdc, 0x008b}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x07, 0x0012}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0xdc, 0x008b}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x01, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x06, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x08, 0x0092}, - {0xa0, 0x83, 0x0093}, - {0xa0, 0x04, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x01, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x08, 0x0092}, - {0xa0, 0x06, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x02, 0x0092}, - {0xa0, 0x11, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x03, 0x0092}, - {0xa0, 0xE7, 0x0093}, - {0xa0, 0x01, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x04, 0x0092}, - {0xa0, 0x87, 0x0093}, - {0xa0, 0x02, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x07, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x30, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x20, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x51, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x35, 0x0092}, - {0xa0, 0x7F, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x30, 0x0092}, - {0xa0, 0x05, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x31, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x58, 0x0092}, - {0xa0, 0x78, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x62, 0x0092}, - {0xa0, 0x11, 0x0093}, - {0xa0, 0x04, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x2B, 0x0092}, - {0xa0, 0x7f, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x2c, 0x0092}, - {0xa0, 0x7f, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x2D, 0x0092}, - {0xa0, 0x7f, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x2e, 0x0092}, - {0xa0, 0x7f, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x10, 0x0087}, - {0xa0, 0xb7, 0x0101}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x0a, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0xdc, ZC3XX_R08B_I2CDEVICEADDR}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x07, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0xdc, ZC3XX_R08B_I2CDEVICEADDR}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x06, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x08, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x83, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x04, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x01, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x08, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x06, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x02, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x11, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x03, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0xE7, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x01, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x04, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x87, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x02, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x07, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x30, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x20, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x51, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x35, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7F, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x30, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x05, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x31, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x58, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x78, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x62, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x11, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x04, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x2B, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7f, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x2c, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7f, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x2D, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7f, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x2e, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7f, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x10, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0xb7, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, {0xa0, 0x09, 0x01ad}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, - {0xa0, 0x60, 0x01a8}, - {0xa0, 0x6c, 0x018d}, - {0xa0, 0x61, 0x0116}, - {0xa0, 0x65, 0x0118}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, + {0xa0, 0x6c, ZC3XX_R18D_YTARGET}, + {0xa0, 0x61, ZC3XX_R116_RGAIN}, + {0xa0, 0x65, ZC3XX_R118_BGAIN}, {0xa0, 0x09, 0x01ad}, {0xa0, 0x15, 0x01ae}, - {0xa0, 0x4c, 0x010a}, /* matrix */ - {0xa0, 0xf1, 0x010b}, - {0xa0, 0x03, 0x010c}, - {0xa0, 0xfe, 0x010d}, - {0xa0, 0x51, 0x010e}, - {0xa0, 0xf1, 0x010f}, - {0xa0, 0xec, 0x0110}, - {0xa0, 0x03, 0x0111}, - {0xa0, 0x51, 0x0112}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - {0xa0, 0x38, 0x0120}, /* gamma > 5 */ - {0xa0, 0x51, 0x0121}, - {0xa0, 0x6e, 0x0122}, - {0xa0, 0x8c, 0x0123}, - {0xa0, 0xa2, 0x0124}, - {0xa0, 0xb6, 0x0125}, - {0xa0, 0xc8, 0x0126}, - {0xa0, 0xd6, 0x0127}, - {0xa0, 0xe2, 0x0128}, - {0xa0, 0xed, 0x0129}, - {0xa0, 0xf5, 0x012a}, - {0xa0, 0xfc, 0x012b}, - {0xa0, 0xff, 0x012c}, - {0xa0, 0xff, 0x012d}, - {0xa0, 0xff, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x12, 0x0130}, - {0xa0, 0x1b, 0x0131}, - {0xa0, 0x1d, 0x0132}, - {0xa0, 0x1a, 0x0133}, - {0xa0, 0x15, 0x0134}, - {0xa0, 0x12, 0x0135}, - {0xa0, 0x0f, 0x0136}, - {0xa0, 0x0d, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x05, 0x013b}, - {0xa0, 0x00, 0x013c}, - {0xa0, 0x00, 0x013d}, - {0xa0, 0x00, 0x013e}, - {0xa0, 0x01, 0x013f}, - {0xa0, 0x4c, 0x010a}, /* matrix */ - {0xa0, 0xf1, 0x010b}, - {0xa0, 0x03, 0x010c}, - {0xa0, 0xfe, 0x010d}, - {0xa0, 0x51, 0x010e}, - {0xa0, 0xf1, 0x010f}, - {0xa0, 0xec, 0x0110}, - {0xa0, 0x03, 0x0111}, - {0xa0, 0x51, 0x0112}, - {0xa0, 0x10, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, - {0xa0, 0x05, 0x0092}, - {0xa0, 0x09, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x09, 0x0092}, - {0xa0, 0x34, 0x0093}, - {0xa0, 0x01, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x07, 0x0191}, - {0xa0, 0xd2, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x9a, 0x0197}, - {0xa0, 0x0e, 0x018c}, - {0xa0, 0x1c, 0x018f}, - {0xa0, 0x14, 0x01a9}, - {0xa0, 0x66, 0x01aa}, - {0xa0, 0xd7, 0x001d}, - {0xa0, 0xf4, 0x001e}, - {0xa0, 0xf9, 0x001f}, - {0xa0, 0xff, 0x0020}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x4c, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf1, ZC3XX_R10B_RGB01}, + {0xa0, 0x03, ZC3XX_R10C_RGB02}, + {0xa0, 0xfe, ZC3XX_R10D_RGB10}, + {0xa0, 0x51, ZC3XX_R10E_RGB11}, + {0xa0, 0xf1, ZC3XX_R10F_RGB12}, + {0xa0, 0xec, ZC3XX_R110_RGB20}, + {0xa0, 0x03, ZC3XX_R111_RGB21}, + {0xa0, 0x51, ZC3XX_R112_RGB22}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x38, ZC3XX_R120_GAMMA00}, /* gamma > 5 */ + {0xa0, 0x51, ZC3XX_R121_GAMMA01}, + {0xa0, 0x6e, ZC3XX_R122_GAMMA02}, + {0xa0, 0x8c, ZC3XX_R123_GAMMA03}, + {0xa0, 0xa2, ZC3XX_R124_GAMMA04}, + {0xa0, 0xb6, ZC3XX_R125_GAMMA05}, + {0xa0, 0xc8, ZC3XX_R126_GAMMA06}, + {0xa0, 0xd6, ZC3XX_R127_GAMMA07}, + {0xa0, 0xe2, ZC3XX_R128_GAMMA08}, + {0xa0, 0xed, ZC3XX_R129_GAMMA09}, + {0xa0, 0xf5, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xfc, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xff, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xff, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xff, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x12, ZC3XX_R130_GAMMA10}, + {0xa0, 0x1b, ZC3XX_R131_GAMMA11}, + {0xa0, 0x1d, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1a, ZC3XX_R133_GAMMA13}, + {0xa0, 0x15, ZC3XX_R134_GAMMA14}, + {0xa0, 0x12, ZC3XX_R135_GAMMA15}, + {0xa0, 0x0f, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0d, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x05, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x00, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x00, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x00, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x01, ZC3XX_R13F_GAMMA1F}, + {0xa0, 0x4c, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf1, ZC3XX_R10B_RGB01}, + {0xa0, 0x03, ZC3XX_R10C_RGB02}, + {0xa0, 0xfe, ZC3XX_R10D_RGB10}, + {0xa0, 0x51, ZC3XX_R10E_RGB11}, + {0xa0, 0xf1, ZC3XX_R10F_RGB12}, + {0xa0, 0xec, ZC3XX_R110_RGB20}, + {0xa0, 0x03, ZC3XX_R111_RGB21}, + {0xa0, 0x51, ZC3XX_R112_RGB22}, + {0xa0, 0x10, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, + {0xa0, 0x05, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x09, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x09, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x34, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x01, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x07, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0xd2, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x9a, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x0e, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x1c, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x14, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x66, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0xd7, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0xf4, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xf9, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa0, 0x09, 0x01ad}, {0xa0, 0x15, 0x01ae}, - {0xa0, 0x40, 0x0180}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {} }; static const struct usb_action tas5130CK_InitialScale[] = { - {0xa0, 0x01, 0x0000}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, {0xa0, 0x01, 0x003b}, {0xa0, 0x0e, 0x003a}, {0xa0, 0x01, 0x0038}, {0xa0, 0x0b, 0x0039}, {0xa0, 0x00, 0x0038}, {0xa0, 0x0b, 0x0039}, - {0xa0, 0x01, 0x0000}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x0a, 0x0010}, - {0xa0, 0x00, 0x0002}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0xdc, 0x008b}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x07, 0x0012}, - {0xa0, 0x00, 0x0098}, - {0xa0, 0x00, 0x009a}, - {0xa0, 0x00, 0x011a}, - {0xa0, 0x00, 0x011c}, - {0xa0, 0xdc, 0x008b}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x01, 0x0092}, - {0xa0, 0x01, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x06, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x08, 0x0092}, - {0xa0, 0x83, 0x0093}, - {0xa0, 0x04, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x01, 0x0092}, - {0xa0, 0x04, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x08, 0x0092}, - {0xa0, 0x06, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x02, 0x0092}, - {0xa0, 0x11, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x03, 0x0092}, - {0xa0, 0xe5, 0x0093}, - {0xa0, 0x01, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x04, 0x0092}, - {0xa0, 0x85, 0x0093}, - {0xa0, 0x02, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x07, 0x0092}, - {0xa0, 0x02, 0x0093}, - {0xa0, 0x30, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x20, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x51, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x35, 0x0092}, - {0xa0, 0x7F, 0x0093}, - {0xa0, 0x50, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x30, 0x0092}, - {0xa0, 0x05, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x31, 0x0092}, - {0xa0, 0x00, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x58, 0x0092}, - {0xa0, 0x78, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x62, 0x0092}, - {0xa0, 0x11, 0x0093}, - {0xa0, 0x04, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x2B, 0x0092}, - {0xa0, 0x7f, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x2C, 0x0092}, - {0xa0, 0x7F, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x2D, 0x0092}, - {0xa0, 0x7f, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x2e, 0x0092}, - {0xa0, 0x7f, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x10, 0x0087}, - {0xa0, 0xb7, 0x0101}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x0a, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0xdc, ZC3XX_R08B_I2CDEVICEADDR}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x07, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0xdc, ZC3XX_R08B_I2CDEVICEADDR}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x01, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x06, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x08, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x83, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x04, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x01, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x04, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x08, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x06, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x02, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x11, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x03, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0xe5, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x01, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x04, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x85, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x02, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x07, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x02, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x30, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x20, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x51, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x35, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7F, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x50, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x30, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x05, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x31, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x00, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x58, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x78, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x62, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x11, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x04, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x2B, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7f, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x2C, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7F, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x2D, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7f, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x2e, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x7f, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x10, ZC3XX_R087_EXPTIMEMID}, + {0xa0, 0xb7, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, {0xa0, 0x09, 0x01ad}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, - {0xa0, 0x60, 0x01a8}, - {0xa0, 0x6c, 0x018d}, - {0xa0, 0x61, 0x0116}, - {0xa0, 0x65, 0x0118}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, + {0xa0, 0x6c, ZC3XX_R18D_YTARGET}, + {0xa0, 0x61, ZC3XX_R116_RGAIN}, + {0xa0, 0x65, ZC3XX_R118_BGAIN}, {0xa0, 0x09, 0x01ad}, {0xa0, 0x15, 0x01ae}, - {0xa0, 0x4c, 0x010a}, /* matrix */ - {0xa0, 0xf1, 0x010b}, - {0xa0, 0x03, 0x010c}, - {0xa0, 0xfe, 0x010d}, - {0xa0, 0x51, 0x010e}, - {0xa0, 0xf1, 0x010f}, - {0xa0, 0xec, 0x0110}, - {0xa0, 0x03, 0x0111}, - {0xa0, 0x51, 0x0112}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - {0xa0, 0x38, 0x0120}, /* gamma > 5 */ - {0xa0, 0x51, 0x0121}, - {0xa0, 0x6e, 0x0122}, - {0xa0, 0x8c, 0x0123}, - {0xa0, 0xa2, 0x0124}, - {0xa0, 0xb6, 0x0125}, - {0xa0, 0xc8, 0x0126}, - {0xa0, 0xd6, 0x0127}, - {0xa0, 0xe2, 0x0128}, - {0xa0, 0xed, 0x0129}, - {0xa0, 0xf5, 0x012a}, - {0xa0, 0xfc, 0x012b}, - {0xa0, 0xff, 0x012c}, - {0xa0, 0xff, 0x012d}, - {0xa0, 0xff, 0x012e}, - {0xa0, 0xff, 0x012f}, - {0xa0, 0x12, 0x0130}, - {0xa0, 0x1b, 0x0131}, - {0xa0, 0x1d, 0x0132}, - {0xa0, 0x1a, 0x0133}, - {0xa0, 0x15, 0x0134}, - {0xa0, 0x12, 0x0135}, - {0xa0, 0x0f, 0x0136}, - {0xa0, 0x0d, 0x0137}, - {0xa0, 0x0b, 0x0138}, - {0xa0, 0x09, 0x0139}, - {0xa0, 0x07, 0x013a}, - {0xa0, 0x05, 0x013b}, - {0xa0, 0x00, 0x013c}, - {0xa0, 0x00, 0x013d}, - {0xa0, 0x00, 0x013e}, - {0xa0, 0x01, 0x013f}, - {0xa0, 0x4c, 0x010a}, /* matrix */ - {0xa0, 0xf1, 0x010b}, - {0xa0, 0x03, 0x010c}, - {0xa0, 0xfe, 0x010d}, - {0xa0, 0x51, 0x010e}, - {0xa0, 0xf1, 0x010f}, - {0xa0, 0xec, 0x0110}, - {0xa0, 0x03, 0x0111}, - {0xa0, 0x51, 0x0112}, - {0xa0, 0x10, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, - {0xa0, 0x05, 0x0092}, - {0xa0, 0x62, 0x0093}, - {0xa0, 0x00, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x09, 0x0092}, - {0xa0, 0xaa, 0x0093}, - {0xa0, 0x01, 0x0094}, - {0xa0, 0x01, 0x0090}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x03, 0x0191}, - {0xa0, 0x9b, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x47, 0x0197}, - {0xa0, 0x0e, 0x018c}, - {0xa0, 0x1c, 0x018f}, - {0xa0, 0x14, 0x01a9}, - {0xa0, 0x66, 0x01aa}, - {0xa0, 0x62, 0x001d}, - {0xa0, 0x90, 0x001e}, - {0xa0, 0xc8, 0x001f}, - {0xa0, 0xff, 0x0020}, - {0xa0, 0x60, 0x011d}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x4c, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf1, ZC3XX_R10B_RGB01}, + {0xa0, 0x03, ZC3XX_R10C_RGB02}, + {0xa0, 0xfe, ZC3XX_R10D_RGB10}, + {0xa0, 0x51, ZC3XX_R10E_RGB11}, + {0xa0, 0xf1, ZC3XX_R10F_RGB12}, + {0xa0, 0xec, ZC3XX_R110_RGB20}, + {0xa0, 0x03, ZC3XX_R111_RGB21}, + {0xa0, 0x51, ZC3XX_R112_RGB22}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + {0xa0, 0x38, ZC3XX_R120_GAMMA00}, /* gamma > 5 */ + {0xa0, 0x51, ZC3XX_R121_GAMMA01}, + {0xa0, 0x6e, ZC3XX_R122_GAMMA02}, + {0xa0, 0x8c, ZC3XX_R123_GAMMA03}, + {0xa0, 0xa2, ZC3XX_R124_GAMMA04}, + {0xa0, 0xb6, ZC3XX_R125_GAMMA05}, + {0xa0, 0xc8, ZC3XX_R126_GAMMA06}, + {0xa0, 0xd6, ZC3XX_R127_GAMMA07}, + {0xa0, 0xe2, ZC3XX_R128_GAMMA08}, + {0xa0, 0xed, ZC3XX_R129_GAMMA09}, + {0xa0, 0xf5, ZC3XX_R12A_GAMMA0A}, + {0xa0, 0xfc, ZC3XX_R12B_GAMMA0B}, + {0xa0, 0xff, ZC3XX_R12C_GAMMA0C}, + {0xa0, 0xff, ZC3XX_R12D_GAMMA0D}, + {0xa0, 0xff, ZC3XX_R12E_GAMMA0E}, + {0xa0, 0xff, ZC3XX_R12F_GAMMA0F}, + {0xa0, 0x12, ZC3XX_R130_GAMMA10}, + {0xa0, 0x1b, ZC3XX_R131_GAMMA11}, + {0xa0, 0x1d, ZC3XX_R132_GAMMA12}, + {0xa0, 0x1a, ZC3XX_R133_GAMMA13}, + {0xa0, 0x15, ZC3XX_R134_GAMMA14}, + {0xa0, 0x12, ZC3XX_R135_GAMMA15}, + {0xa0, 0x0f, ZC3XX_R136_GAMMA16}, + {0xa0, 0x0d, ZC3XX_R137_GAMMA17}, + {0xa0, 0x0b, ZC3XX_R138_GAMMA18}, + {0xa0, 0x09, ZC3XX_R139_GAMMA19}, + {0xa0, 0x07, ZC3XX_R13A_GAMMA1A}, + {0xa0, 0x05, ZC3XX_R13B_GAMMA1B}, + {0xa0, 0x00, ZC3XX_R13C_GAMMA1C}, + {0xa0, 0x00, ZC3XX_R13D_GAMMA1D}, + {0xa0, 0x00, ZC3XX_R13E_GAMMA1E}, + {0xa0, 0x01, ZC3XX_R13F_GAMMA1F}, + {0xa0, 0x4c, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xf1, ZC3XX_R10B_RGB01}, + {0xa0, 0x03, ZC3XX_R10C_RGB02}, + {0xa0, 0xfe, ZC3XX_R10D_RGB10}, + {0xa0, 0x51, ZC3XX_R10E_RGB11}, + {0xa0, 0xf1, ZC3XX_R10F_RGB12}, + {0xa0, 0xec, ZC3XX_R110_RGB20}, + {0xa0, 0x03, ZC3XX_R111_RGB21}, + {0xa0, 0x51, ZC3XX_R112_RGB22}, + {0xa0, 0x10, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, + {0xa0, 0x05, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0x62, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x00, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x09, ZC3XX_R092_I2CADDRESSSELECT}, + {0xa0, 0xaa, ZC3XX_R093_I2CSETVALUE}, + {0xa0, 0x01, ZC3XX_R094_I2CWRITEACK}, + {0xa0, 0x01, ZC3XX_R090_I2CCOMMAND}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x03, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0x9b, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x47, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x0e, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x1c, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x14, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x66, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0x62, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xc8, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x60, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa0, 0x09, 0x01ad}, {0xa0, 0x15, 0x01ae}, - {0xa0, 0x40, 0x0180}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa0, 0x30, 0x0007}, - {0xa0, 0x02, 0x0008}, + {0xa0, 0x02, ZC3XX_R008_CLOCKSETTING}, {0xa0, 0x00, 0x0007}, - {0xa0, 0x03, 0x0008}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, {} }; static const struct usb_action tas5130cxx_Initial[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x50, 0x0002}, - {0xa0, 0x03, 0x0008}, - {0xa0, 0x02, 0x0010}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x00, 0x0001}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x07, 0x00a5}, - {0xa0, 0x02, 0x00a6}, - - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - - {0xa0, 0x04, 0x0098}, - {0xa0, 0x0f, 0x009a}, - {0xa0, 0x04, 0x011a}, - {0xa0, 0x0f, 0x011c}, - {0xa0, 0xe8, 0x009c}, - {0xa0, 0x02, 0x009d}, - {0xa0, 0x88, 0x009e}, - {0xa0, 0x06, 0x008d}, - {0xa0, 0xf7, 0x0101}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x68, 0x018d}, - {0xa0, 0x60, 0x01a8}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x50, ZC3XX_R002_CLOCKSELECT}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, + {0xa0, 0x02, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x00, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x07, ZC3XX_R0A5_EXPOSUREGAIN}, + {0xa0, 0x02, ZC3XX_R0A6_EXPOSUREBLACKLVL}, + + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + + {0xa0, 0x04, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x0f, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x04, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x0f, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0xe8, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x02, ZC3XX_R09D_WINWIDTHHIGH}, + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, + {0xa0, 0x06, ZC3XX_R08D_COMPABILITYMODE}, + {0xa0, 0xf7, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x68, ZC3XX_R18D_YTARGET}, + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, {0xa0, 0x00, 0x01ad}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, {0xa1, 0x01, 0x0002}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, /* clock ? */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - - {0xa0, 0x68, 0x010a}, /* matrix */ - {0xa0, 0xec, 0x010b}, - {0xa0, 0xec, 0x010c}, - {0xa0, 0xec, 0x010d}, - {0xa0, 0x68, 0x010e}, - {0xa0, 0xec, 0x010f}, - {0xa0, 0xec, 0x0110}, - {0xa0, 0xec, 0x0111}, - {0xa0, 0x68, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + + {0xa0, 0x68, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xec, ZC3XX_R10B_RGB01}, + {0xa0, 0xec, ZC3XX_R10C_RGB02}, + {0xa0, 0xec, ZC3XX_R10D_RGB10}, + {0xa0, 0x68, ZC3XX_R10E_RGB11}, + {0xa0, 0xec, ZC3XX_R10F_RGB12}, + {0xa0, 0xec, ZC3XX_R110_RGB20}, + {0xa0, 0xec, ZC3XX_R111_RGB21}, + {0xa0, 0x68, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x018d}, - {0xa0, 0x90, 0x018d}, /* 90 */ + {0xa0, 0x90, ZC3XX_R18D_YTARGET}, /* 90 */ {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0xa3, 0x0001}, {0xaa, 0xa4, 0x0077}, - {0xa0, 0x01, 0x00a3}, - {0xa0, 0x77, 0x00a4}, - - {0xa0, 0x00, 0x0190}, /* 00 */ - {0xa0, 0x03, 0x0191}, /* 03 */ - {0xa0, 0xe8, 0x0192}, /* e8 */ - {0xa0, 0x00, 0x0195}, /* 0 */ - {0xa0, 0x00, 0x0196}, /* 0 */ - {0xa0, 0x7d, 0x0197}, /* 7d */ - - {0xa0, 0x0c, 0x018c}, - {0xa0, 0x18, 0x018f}, - {0xa0, 0x08, 0x01a9}, /* 08 */ - {0xa0, 0x24, 0x01aa}, /* 24 */ - {0xa0, 0xf0, 0x001d}, - {0xa0, 0xf4, 0x001e}, - {0xa0, 0xf8, 0x001f}, - {0xa0, 0xff, 0x0020}, - {0xa0, 0x03, 0x009f}, - {0xa0, 0xc0, 0x00a0}, - {0xa0, 0x50, 0x011d}, /* 50 */ - {0xa0, 0x40, 0x0180}, + {0xa0, 0x01, ZC3XX_R0A3_EXPOSURETIMEHIGH}, + {0xa0, 0x77, ZC3XX_R0A4_EXPOSURETIMELOW}, + + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 00 */ + {0xa0, 0x03, ZC3XX_R191_EXPOSURELIMITMID}, /* 03 */ + {0xa0, 0xe8, ZC3XX_R192_EXPOSURELIMITLOW}, /* e8 */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 0 */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 0 */ + {0xa0, 0x7d, ZC3XX_R197_ANTIFLICKERLOW}, /* 7d */ + + {0xa0, 0x0c, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x18, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x08, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 08 */ + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 24 */ + {0xa0, 0xf0, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0xf4, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xf8, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x03, ZC3XX_R09F_MAXXHIGH}, + {0xa0, 0xc0, ZC3XX_R0A0_MAXXLOW}, + {0xa0, 0x50, ZC3XX_R11D_GLOBALGAIN}, /* 50 */ + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {} }; static const struct usb_action tas5130cxx_InitialScale[] = { - {0xa0, 0x01, 0x0000}, - {0xa0, 0x01, 0x0000}, - {0xa0, 0x40, 0x0002}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, + {0xa0, 0x40, ZC3XX_R002_CLOCKSELECT}, - {0xa0, 0x03, 0x0008}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x02, 0x0010}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x00, 0x0001}, - {0xa0, 0x01, 0x0012}, - {0xa0, 0x01, 0x0001}, - {0xa0, 0x05, 0x0012}, - {0xa0, 0x07, 0x00a5}, - {0xa0, 0x02, 0x00a6}, - {0xa0, 0x02, 0x0003}, - {0xa0, 0x80, 0x0004}, - {0xa0, 0x01, 0x0005}, - {0xa0, 0xe0, 0x0006}, - {0xa0, 0x05, 0x0098}, - {0xa0, 0x0f, 0x009a}, - {0xa0, 0x05, 0x011a}, - {0xa0, 0x0f, 0x011c}, - {0xa0, 0xe6, 0x009c}, - {0xa0, 0x02, 0x009d}, - {0xa0, 0x86, 0x009e}, - {0xa0, 0x06, 0x008d}, - {0xa0, 0x37, 0x0101}, - {0xa0, 0x0d, 0x0100}, - {0xa0, 0x06, 0x0189}, - {0xa0, 0x68, 0x018d}, - {0xa0, 0x60, 0x01a8}, + {0xa0, 0x02, ZC3XX_R010_CMOSSENSORSELECT}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x00, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, + {0xa0, 0x07, ZC3XX_R0A5_EXPOSUREGAIN}, + {0xa0, 0x02, ZC3XX_R0A6_EXPOSUREBLACKLVL}, + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, + {0xa0, 0x05, ZC3XX_R098_WINYSTARTLOW}, + {0xa0, 0x0f, ZC3XX_R09A_WINXSTARTLOW}, + {0xa0, 0x05, ZC3XX_R11A_FIRSTYLOW}, + {0xa0, 0x0f, ZC3XX_R11C_FIRSTXLOW}, + {0xa0, 0xe6, ZC3XX_R09C_WINHEIGHTLOW}, + {0xa0, 0x02, ZC3XX_R09D_WINWIDTHHIGH}, + {0xa0, 0x86, ZC3XX_R09E_WINWIDTHLOW}, + {0xa0, 0x06, ZC3XX_R08D_COMPABILITYMODE}, + {0xa0, 0x37, ZC3XX_R101_SENSORCORRECTION}, + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, + {0xa0, 0x06, ZC3XX_R189_AWBSTATUS}, + {0xa0, 0x68, ZC3XX_R18D_YTARGET}, + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, {0xa0, 0x00, 0x01ad}, - {0xa0, 0x03, 0x01c5}, - {0xa0, 0x13, 0x01cb}, - {0xa0, 0x08, 0x0250}, - {0xa0, 0x08, 0x0301}, + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, {0xa1, 0x01, 0x0002}, {0xa1, 0x01, 0x0008}, - {0xa0, 0x03, 0x0008}, + {0xa0, 0x03, ZC3XX_R008_CLOCKSETTING}, {0xa1, 0x01, 0x0008}, /* clock ? */ - {0xa0, 0x08, 0x01c6}, /* sharpness+ */ + {0xa0, 0x08, ZC3XX_R1C6_SHARPNESS00}, /* sharpness+ */ {0xa1, 0x01, 0x01c8}, {0xa1, 0x01, 0x01c9}, {0xa1, 0x01, 0x01ca}, - {0xa0, 0x0f, 0x01cb}, /* sharpness- */ - - {0xa0, 0x68, 0x010a}, /* matrix */ - {0xa0, 0xec, 0x010b}, - {0xa0, 0xec, 0x010c}, - {0xa0, 0xec, 0x010d}, - {0xa0, 0x68, 0x010e}, - {0xa0, 0xec, 0x010f}, - {0xa0, 0xec, 0x0110}, - {0xa0, 0xec, 0x0111}, - {0xa0, 0x68, 0x0112}, + {0xa0, 0x0f, ZC3XX_R1CB_SHARPNESS05}, /* sharpness- */ + + {0xa0, 0x68, ZC3XX_R10A_RGB00}, /* matrix */ + {0xa0, 0xec, ZC3XX_R10B_RGB01}, + {0xa0, 0xec, ZC3XX_R10C_RGB02}, + {0xa0, 0xec, ZC3XX_R10D_RGB10}, + {0xa0, 0x68, ZC3XX_R10E_RGB11}, + {0xa0, 0xec, ZC3XX_R10F_RGB12}, + {0xa0, 0xec, ZC3XX_R110_RGB20}, + {0xa0, 0xec, ZC3XX_R111_RGB21}, + {0xa0, 0x68, ZC3XX_R112_RGB22}, {0xa1, 0x01, 0x018d}, - {0xa0, 0x90, 0x018d}, + {0xa0, 0x90, ZC3XX_R18D_YTARGET}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x00, 0x0180}, - {0xa0, 0x00, 0x0019}, + {0xa0, 0x00, ZC3XX_R180_AUTOCORRECTENABLE}, + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, {0xaa, 0xa3, 0x0001}, {0xaa, 0xa4, 0x0063}, - {0xa0, 0x01, 0x00a3}, - {0xa0, 0x63, 0x00a4}, - {0xa0, 0x00, 0x0190}, - {0xa0, 0x02, 0x0191}, - {0xa0, 0x38, 0x0192}, - {0xa0, 0x00, 0x0195}, - {0xa0, 0x00, 0x0196}, - {0xa0, 0x47, 0x0197}, - {0xa0, 0x0c, 0x018c}, - {0xa0, 0x18, 0x018f}, - {0xa0, 0x08, 0x01a9}, - {0xa0, 0x24, 0x01aa}, - {0xa0, 0xd3, 0x001d}, - {0xa0, 0xda, 0x001e}, - {0xa0, 0xea, 0x001f}, - {0xa0, 0xff, 0x0020}, - {0xa0, 0x03, 0x009f}, - {0xa0, 0x4c, 0x00a0}, - {0xa0, 0x50, 0x011d}, - {0xa0, 0x40, 0x0180}, + {0xa0, 0x01, ZC3XX_R0A3_EXPOSURETIMEHIGH}, + {0xa0, 0x63, ZC3XX_R0A4_EXPOSURETIMELOW}, + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, + {0xa0, 0x02, ZC3XX_R191_EXPOSURELIMITMID}, + {0xa0, 0x38, ZC3XX_R192_EXPOSURELIMITLOW}, + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, + {0xa0, 0x47, ZC3XX_R197_ANTIFLICKERLOW}, + {0xa0, 0x0c, ZC3XX_R18C_AEFREEZE}, + {0xa0, 0x18, ZC3XX_R18F_AEUNFREEZE}, + {0xa0, 0x08, ZC3XX_R1A9_DIGITALLIMITDIFF}, + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, + {0xa0, 0xd3, ZC3XX_R01D_HSYNC_0}, + {0xa0, 0xda, ZC3XX_R01E_HSYNC_1}, + {0xa0, 0xea, ZC3XX_R01F_HSYNC_2}, + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, + {0xa0, 0x03, ZC3XX_R09F_MAXXHIGH}, + {0xa0, 0x4c, ZC3XX_R0A0_MAXXLOW}, + {0xa0, 0x50, ZC3XX_R11D_GLOBALGAIN}, + {0xa0, 0x40, ZC3XX_R180_AUTOCORRECTENABLE}, {0xa1, 0x01, 0x0180}, - {0xa0, 0x42, 0x0180}, + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, {} }; static const struct usb_action tas5130cxx_50HZ[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0xa3, 0x0001}, /* 00,a3,01,aa */ {0xaa, 0xa4, 0x0063}, /* 00,a4,63,aa */ - {0xa0, 0x01, 0x00a3}, /* 00,a3,01,cc */ - {0xa0, 0x63, 0x00a4}, /* 00,a4,63,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x02, 0x0191}, /* 01,91,02,cc */ - {0xa0, 0x38, 0x0192}, /* 01,92,38,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x47, 0x0197}, /* 01,97,47,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x0c, 0x01a9}, /* 01,a9,0c,cc */ - {0xa0, 0x26, 0x01aa}, /* 01,aa,26,cc */ - {0xa0, 0xd3, 0x001d}, /* 00,1d,d3,cc */ - {0xa0, 0xda, 0x001e}, /* 00,1e,da,cc */ - {0xa0, 0xea, 0x001f}, /* 00,1f,ea,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ - {0xa0, 0x03, 0x009f}, /* 00,9f,03,cc */ + {0xa0, 0x01, ZC3XX_R0A3_EXPOSURETIMEHIGH}, /* 00,a3,01,cc */ + {0xa0, 0x63, ZC3XX_R0A4_EXPOSURETIMELOW}, /* 00,a4,63,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x02, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,02,cc */ + {0xa0, 0x38, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,38,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x47, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,47,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,0c,cc */ + {0xa0, 0x26, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,26,cc */ + {0xa0, 0xd3, ZC3XX_R01D_HSYNC_0}, /* 00,1d,d3,cc */ + {0xa0, 0xda, ZC3XX_R01E_HSYNC_1}, /* 00,1e,da,cc */ + {0xa0, 0xea, ZC3XX_R01F_HSYNC_2}, /* 00,1f,ea,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ + {0xa0, 0x03, ZC3XX_R09F_MAXXHIGH}, /* 00,9f,03,cc */ {} }; static const struct usb_action tas5130cxx_50HZScale[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0xa3, 0x0001}, /* 00,a3,01,aa */ {0xaa, 0xa4, 0x0077}, /* 00,a4,77,aa */ - {0xa0, 0x01, 0x00a3}, /* 00,a3,01,cc */ - {0xa0, 0x77, 0x00a4}, /* 00,a4,77,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x03, 0x0191}, /* 01,91,03,cc */ - {0xa0, 0xe8, 0x0192}, /* 01,92,e8,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x7d, 0x0197}, /* 01,97,7d,cc */ - {0xa0, 0x14, 0x018c}, /* 01,8c,14,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x0c, 0x01a9}, /* 01,a9,0c,cc */ - {0xa0, 0x26, 0x01aa}, /* 01,aa,26,cc */ - {0xa0, 0xf0, 0x001d}, /* 00,1d,f0,cc */ - {0xa0, 0xf4, 0x001e}, /* 00,1e,f4,cc */ - {0xa0, 0xf8, 0x001f}, /* 00,1f,f8,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ - {0xa0, 0x03, 0x009f}, /* 00,9f,03,cc */ + {0xa0, 0x01, ZC3XX_R0A3_EXPOSURETIMEHIGH}, /* 00,a3,01,cc */ + {0xa0, 0x77, ZC3XX_R0A4_EXPOSURETIMELOW}, /* 00,a4,77,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x03, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,03,cc */ + {0xa0, 0xe8, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,e8,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x7d, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,7d,cc */ + {0xa0, 0x14, ZC3XX_R18C_AEFREEZE}, /* 01,8c,14,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,0c,cc */ + {0xa0, 0x26, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,26,cc */ + {0xa0, 0xf0, ZC3XX_R01D_HSYNC_0}, /* 00,1d,f0,cc */ + {0xa0, 0xf4, ZC3XX_R01E_HSYNC_1}, /* 00,1e,f4,cc */ + {0xa0, 0xf8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,f8,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ + {0xa0, 0x03, ZC3XX_R09F_MAXXHIGH}, /* 00,9f,03,cc */ {} }; static const struct usb_action tas5130cxx_60HZ[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0xa3, 0x0001}, /* 00,a3,01,aa */ {0xaa, 0xa4, 0x0036}, /* 00,a4,36,aa */ - {0xa0, 0x01, 0x00a3}, /* 00,a3,01,cc */ - {0xa0, 0x36, 0x00a4}, /* 00,a4,36,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x01, 0x0191}, /* 01,91,01,cc */ - {0xa0, 0xf0, 0x0192}, /* 01,92,f0,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x3e, 0x0197}, /* 01,97,3e,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x0c, 0x01a9}, /* 01,a9,0c,cc */ - {0xa0, 0x26, 0x01aa}, /* 01,aa,26,cc */ - {0xa0, 0xca, 0x001d}, /* 00,1d,ca,cc */ - {0xa0, 0xd0, 0x001e}, /* 00,1e,d0,cc */ - {0xa0, 0xe0, 0x001f}, /* 00,1f,e0,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ - {0xa0, 0x03, 0x009f}, /* 00,9f,03,cc */ + {0xa0, 0x01, ZC3XX_R0A3_EXPOSURETIMEHIGH}, /* 00,a3,01,cc */ + {0xa0, 0x36, ZC3XX_R0A4_EXPOSURETIMELOW}, /* 00,a4,36,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x01, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,01,cc */ + {0xa0, 0xf0, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,f0,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x3e, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,3e,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,0c,cc */ + {0xa0, 0x26, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,26,cc */ + {0xa0, 0xca, ZC3XX_R01D_HSYNC_0}, /* 00,1d,ca,cc */ + {0xa0, 0xd0, ZC3XX_R01E_HSYNC_1}, /* 00,1e,d0,cc */ + {0xa0, 0xe0, ZC3XX_R01F_HSYNC_2}, /* 00,1f,e0,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ + {0xa0, 0x03, ZC3XX_R09F_MAXXHIGH}, /* 00,9f,03,cc */ {} }; static const struct usb_action tas5130cxx_60HZScale[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0xa3, 0x0001}, /* 00,a3,01,aa */ {0xaa, 0xa4, 0x0077}, /* 00,a4,77,aa */ - {0xa0, 0x01, 0x00a3}, /* 00,a3,01,cc */ - {0xa0, 0x77, 0x00a4}, /* 00,a4,77,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x03, 0x0191}, /* 01,91,03,cc */ - {0xa0, 0xe8, 0x0192}, /* 01,92,e8,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x7d, 0x0197}, /* 01,97,7d,cc */ - {0xa0, 0x14, 0x018c}, /* 01,8c,14,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x0c, 0x01a9}, /* 01,a9,0c,cc */ - {0xa0, 0x26, 0x01aa}, /* 01,aa,26,cc */ - {0xa0, 0xc8, 0x001d}, /* 00,1d,c8,cc */ - {0xa0, 0xd0, 0x001e}, /* 00,1e,d0,cc */ - {0xa0, 0xe0, 0x001f}, /* 00,1f,e0,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ - {0xa0, 0x03, 0x009f}, /* 00,9f,03,cc */ + {0xa0, 0x01, ZC3XX_R0A3_EXPOSURETIMEHIGH}, /* 00,a3,01,cc */ + {0xa0, 0x77, ZC3XX_R0A4_EXPOSURETIMELOW}, /* 00,a4,77,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x03, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,03,cc */ + {0xa0, 0xe8, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,e8,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x7d, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,7d,cc */ + {0xa0, 0x14, ZC3XX_R18C_AEFREEZE}, /* 01,8c,14,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x0c, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,0c,cc */ + {0xa0, 0x26, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,26,cc */ + {0xa0, 0xc8, ZC3XX_R01D_HSYNC_0}, /* 00,1d,c8,cc */ + {0xa0, 0xd0, ZC3XX_R01E_HSYNC_1}, /* 00,1e,d0,cc */ + {0xa0, 0xe0, ZC3XX_R01F_HSYNC_2}, /* 00,1f,e0,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ + {0xa0, 0x03, ZC3XX_R09F_MAXXHIGH}, /* 00,9f,03,cc */ {} }; static const struct usb_action tas5130cxx_NoFliker[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0xa3, 0x0001}, /* 00,a3,01,aa */ {0xaa, 0xa4, 0x0040}, /* 00,a4,40,aa */ - {0xa0, 0x01, 0x00a3}, /* 00,a3,01,cc */ - {0xa0, 0x40, 0x00a4}, /* 00,a4,40,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x01, 0x0191}, /* 01,91,01,cc */ - {0xa0, 0xf0, 0x0192}, /* 01,92,f0,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x10, 0x0197}, /* 01,97,10,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x00, 0x01a9}, /* 01,a9,00,cc */ - {0xa0, 0x00, 0x01aa}, /* 01,aa,00,cc */ - {0xa0, 0xbc, 0x001d}, /* 00,1d,bc,cc */ - {0xa0, 0xd0, 0x001e}, /* 00,1e,d0,cc */ - {0xa0, 0xe0, 0x001f}, /* 00,1f,e0,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ - {0xa0, 0x02, 0x009f}, /* 00,9f,02,cc */ + {0xa0, 0x01, ZC3XX_R0A3_EXPOSURETIMEHIGH}, /* 00,a3,01,cc */ + {0xa0, 0x40, ZC3XX_R0A4_EXPOSURETIMELOW}, /* 00,a4,40,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x01, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,01,cc */ + {0xa0, 0xf0, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,f0,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x10, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,10,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x00, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,00,cc */ + {0xa0, 0x00, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,00,cc */ + {0xa0, 0xbc, ZC3XX_R01D_HSYNC_0}, /* 00,1d,bc,cc */ + {0xa0, 0xd0, ZC3XX_R01E_HSYNC_1}, /* 00,1e,d0,cc */ + {0xa0, 0xe0, ZC3XX_R01F_HSYNC_2}, /* 00,1f,e0,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ + {0xa0, 0x02, ZC3XX_R09F_MAXXHIGH}, /* 00,9f,02,cc */ {} }; static const struct usb_action tas5130cxx_NoFlikerScale[] = { - {0xa0, 0x00, 0x0019}, /* 00,19,00,cc */ + {0xa0, 0x00, ZC3XX_R019_AUTOADJUSTFPS}, /* 00,19,00,cc */ {0xaa, 0xa3, 0x0001}, /* 00,a3,01,aa */ {0xaa, 0xa4, 0x0090}, /* 00,a4,90,aa */ - {0xa0, 0x01, 0x00a3}, /* 00,a3,01,cc */ - {0xa0, 0x90, 0x00a4}, /* 00,a4,90,cc */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc */ - {0xa0, 0x03, 0x0191}, /* 01,91,03,cc */ - {0xa0, 0xf0, 0x0192}, /* 01,92,f0,cc */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc */ - {0xa0, 0x10, 0x0197}, /* 01,97,10,cc */ - {0xa0, 0x10, 0x018c}, /* 01,8c,10,cc */ - {0xa0, 0x20, 0x018f}, /* 01,8f,20,cc */ - {0xa0, 0x00, 0x01a9}, /* 01,a9,00,cc */ - {0xa0, 0x00, 0x01aa}, /* 01,aa,00,cc */ - {0xa0, 0xbc, 0x001d}, /* 00,1d,bc,cc */ - {0xa0, 0xd0, 0x001e}, /* 00,1e,d0,cc */ - {0xa0, 0xe0, 0x001f}, /* 00,1f,e0,cc */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc */ - {0xa0, 0x02, 0x009f}, /* 00,9f,02,cc */ + {0xa0, 0x01, ZC3XX_R0A3_EXPOSURETIMEHIGH}, /* 00,a3,01,cc */ + {0xa0, 0x90, ZC3XX_R0A4_EXPOSURETIMELOW}, /* 00,a4,90,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc */ + {0xa0, 0x03, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,03,cc */ + {0xa0, 0xf0, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,f0,cc */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc */ + {0xa0, 0x10, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,10,cc */ + {0xa0, 0x10, ZC3XX_R18C_AEFREEZE}, /* 01,8c,10,cc */ + {0xa0, 0x20, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,20,cc */ + {0xa0, 0x00, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,00,cc */ + {0xa0, 0x00, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,00,cc */ + {0xa0, 0xbc, ZC3XX_R01D_HSYNC_0}, /* 00,1d,bc,cc */ + {0xa0, 0xd0, ZC3XX_R01E_HSYNC_1}, /* 00,1e,d0,cc */ + {0xa0, 0xe0, ZC3XX_R01F_HSYNC_2}, /* 00,1f,e0,cc */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc */ + {0xa0, 0x02, ZC3XX_R09F_MAXXHIGH}, /* 00,9f,02,cc */ {} }; static const struct usb_action tas5130c_vf0250_Initial[] = { - {0xa0, 0x01, 0x0000}, /* 00,00,01,cc, */ - {0xa0, 0x02, 0x0008}, /* 00,08,02,cc, */ - {0xa0, 0x01, 0x0010}, /* 00,10,01,cc, */ - {0xa0, 0x10, 0x0002}, /* 00,02,00,cc, 0<->10 */ - {0xa0, 0x02, 0x0003}, /* 00,03,02,cc, */ - {0xa0, 0x80, 0x0004}, /* 00,04,80,cc, */ - {0xa0, 0x01, 0x0005}, /* 00,05,01,cc, */ - {0xa0, 0xe0, 0x0006}, /* 00,06,e0,cc, */ - {0xa0, 0x98, 0x008b}, /* 00,8b,98,cc, */ - {0xa0, 0x01, 0x0001}, /* 00,01,01,cc, */ - {0xa0, 0x03, 0x0012}, /* 00,12,03,cc, */ - {0xa0, 0x01, 0x0012}, /* 00,12,01,cc, */ - {0xa0, 0x00, 0x0098}, /* 00,98,00,cc, */ - {0xa0, 0x00, 0x009a}, /* 00,9a,00,cc, */ - {0xa0, 0x00, 0x011a}, /* 01,1a,00,cc, */ - {0xa0, 0x00, 0x011c}, /* 01,1c,00,cc, */ - {0xa0, 0xe8, 0x009c}, /* 00,9c,e6,cc, 6<->8 */ - {0xa0, 0x88, 0x009e}, /* 00,9e,86,cc, 6<->8 */ - {0xa0, 0x10, 0x0087}, /* 00,87,10,cc, */ - {0xa0, 0x98, 0x008b}, /* 00,8b,98,cc, */ + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, /* 00,00,01,cc, */ + {0xa0, 0x02, ZC3XX_R008_CLOCKSETTING}, /* 00,08,02,cc, */ + {0xa0, 0x01, ZC3XX_R010_CMOSSENSORSELECT}, /* 00,10,01,cc, */ + {0xa0, 0x10, ZC3XX_R002_CLOCKSELECT}, /* 00,02,00,cc, + * 0<->10 */ + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, /* 00,03,02,cc, */ + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, /* 00,04,80,cc, */ + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, /* 00,05,01,cc, */ + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, /* 00,06,e0,cc, */ + {0xa0, 0x98, ZC3XX_R08B_I2CDEVICEADDR}, /* 00,8b,98,cc, */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, /* 00,01,01,cc, */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,03,cc, */ + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,01,cc, */ + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, /* 00,98,00,cc, */ + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, /* 00,9a,00,cc, */ + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, /* 01,1a,00,cc, */ + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, /* 01,1c,00,cc, */ + {0xa0, 0xe8, ZC3XX_R09C_WINHEIGHTLOW}, /* 00,9c,e6,cc, + * 6<->8 */ + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, /* 00,9e,86,cc, + * 6<->8 */ + {0xa0, 0x10, ZC3XX_R087_EXPTIMEMID}, /* 00,87,10,cc, */ + {0xa0, 0x98, ZC3XX_R08B_I2CDEVICEADDR}, /* 00,8b,98,cc, */ {0xaa, 0x1b, 0x0024}, /* 00,1b,24,aa, */ {0xdd, 0x00, 0x0080}, /* 00,00,80,dd, */ {0xaa, 0x1b, 0x0000}, /* 00,1b,00,aa, */ {0xaa, 0x13, 0x0002}, /* 00,13,02,aa, */ {0xaa, 0x15, 0x0004}, /* 00,15,04,aa */ - {0xaa, 0x01, 0x0000}, +/*?? {0xaa, 0x01, 0x0000}, */ {0xaa, 0x01, 0x0000}, {0xaa, 0x1a, 0x0000}, /* 00,1a,00,aa, */ {0xaa, 0x1c, 0x0017}, /* 00,1c,17,aa, */ - {0xa0, 0x82, 0x0086}, /* 00,86,82,cc, */ - {0xa0, 0x83, 0x0087}, /* 00,87,83,cc, */ - {0xa0, 0x84, 0x0088}, /* 00,88,84,cc, */ + {0xa0, 0x82, ZC3XX_R086_EXPTIMEHIGH}, /* 00,86,82,cc, */ + {0xa0, 0x83, ZC3XX_R087_EXPTIMEMID}, /* 00,87,83,cc, */ + {0xa0, 0x84, ZC3XX_R088_EXPTIMELOW}, /* 00,88,84,cc, */ {0xaa, 0x05, 0x0010}, /* 00,05,10,aa, */ {0xaa, 0x0a, 0x0000}, /* 00,0a,00,aa, */ {0xaa, 0x0b, 0x00a0}, /* 00,0b,a0,aa, */ @@ -5987,49 +6002,51 @@ static const struct usb_action tas5130c_vf0250_Initial[] = { {0xaa, 0x0f, 0x00a0}, /* 00,0f,a0,aa, */ {0xaa, 0x10, 0x0000}, /* 00,10,00,aa, */ {0xaa, 0x11, 0x00a0}, /* 00,11,a0,aa, */ - {0xa0, 0x00, 0x0039}, - {0xa1, 0x01, 0x0037}, +/*?? {0xa0, 0x00, 0x0039}, + {0xa1, 0x01, 0x0037}, */ {0xaa, 0x16, 0x0001}, /* 00,16,01,aa, */ {0xaa, 0x17, 0x00e8}, /* 00,17,e6,aa, (e6 -> e8) */ {0xaa, 0x18, 0x0002}, /* 00,18,02,aa, */ {0xaa, 0x19, 0x0088}, /* 00,19,86,aa, */ {0xaa, 0x20, 0x0020}, /* 00,20,20,aa, */ - {0xa0, 0xb7, 0x0101}, /* 01,01,b7,cc, */ - {0xa0, 0x05, 0x0012}, /* 00,12,05,cc, */ - {0xa0, 0x0d, 0x0100}, /* 01,00,0d,cc, */ - {0xa0, 0x76, 0x0189}, /* 01,89,76,cc, */ - {0xa0, 0x09, 0x01ad}, /* 01,ad,09,cc, */ - {0xa0, 0x03, 0x01c5}, /* 01,c5,03,cc, */ - {0xa0, 0x13, 0x01cb}, /* 01,cb,13,cc, */ - {0xa0, 0x08, 0x0250}, /* 02,50,08,cc, */ - {0xa0, 0x08, 0x0301}, /* 03,01,08,cc, */ - {0xa0, 0x60, 0x01a8}, /* 01,a8,60,cc, */ - {0xa0, 0x61, 0x0116}, /* 01,16,61,cc, */ - {0xa0, 0x65, 0x0118}, /* 01,18,65,cc */ + {0xa0, 0xb7, ZC3XX_R101_SENSORCORRECTION}, /* 01,01,b7,cc, */ + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,05,cc, */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* 01,00,0d,cc, */ + {0xa0, 0x76, ZC3XX_R189_AWBSTATUS}, /* 01,89,76,cc, */ + {0xa0, 0x09, 0x01ad}, /* 01,ad,09,cc, */ + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, /* 01,c5,03,cc, */ + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, /* 01,cb,13,cc, */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* 02,50,08,cc, */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* 03,01,08,cc, */ + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, /* 01,a8,60,cc, */ + {0xa0, 0x61, ZC3XX_R116_RGAIN}, /* 01,16,61,cc, */ + {0xa0, 0x65, ZC3XX_R118_BGAIN}, /* 01,18,65,cc */ {} }; static const struct usb_action tas5130c_vf0250_InitialScale[] = { - {0xa0, 0x01, 0x0000}, /* 00,00,01,cc, */ - {0xa0, 0x02, 0x0008}, /* 00,08,02,cc, */ - {0xa0, 0x01, 0x0010}, /* 00,10,01,cc, */ - {0xa0, 0x00, 0x0002}, /* 00,02,10,cc, */ - {0xa0, 0x02, 0x0003}, /* 00,03,02,cc, */ - {0xa0, 0x80, 0x0004}, /* 00,04,80,cc, */ - {0xa0, 0x01, 0x0005}, /* 00,05,01,cc, */ - {0xa0, 0xe0, 0x0006}, /* 00,06,e0,cc, */ - {0xa0, 0x98, 0x008b}, /* 00,8b,98,cc, */ - {0xa0, 0x01, 0x0001}, /* 00,01,01,cc, */ - {0xa0, 0x03, 0x0012}, /* 00,12,03,cc, */ - {0xa0, 0x01, 0x0012}, /* 00,12,01,cc, */ - {0xa0, 0x00, 0x0098}, /* 00,98,00,cc, */ - {0xa0, 0x00, 0x009a}, /* 00,9a,00,cc, */ - {0xa0, 0x00, 0x011a}, /* 01,1a,00,cc, */ - {0xa0, 0x00, 0x011c}, /* 01,1c,00,cc, */ - {0xa0, 0xe8, 0x009c}, /* 00,9c,e8,cc, 8<->6 */ - {0xa0, 0x88, 0x009e}, /* 00,9e,88,cc, 8<->6 */ - {0xa0, 0x10, 0x0087}, /* 00,87,10,cc, */ - {0xa0, 0x98, 0x008b}, /* 00,8b,98,cc, */ + {0xa0, 0x01, ZC3XX_R000_SYSTEMCONTROL}, /* 00,00,01,cc, */ + {0xa0, 0x02, ZC3XX_R008_CLOCKSETTING}, /* 00,08,02,cc, */ + {0xa0, 0x01, ZC3XX_R010_CMOSSENSORSELECT}, /* 00,10,01,cc, */ + {0xa0, 0x00, ZC3XX_R002_CLOCKSELECT}, /* 00,02,10,cc, */ + {0xa0, 0x02, ZC3XX_R003_FRAMEWIDTHHIGH}, /* 00,03,02,cc, */ + {0xa0, 0x80, ZC3XX_R004_FRAMEWIDTHLOW}, /* 00,04,80,cc, */ + {0xa0, 0x01, ZC3XX_R005_FRAMEHEIGHTHIGH}, /* 00,05,01,cc, */ + {0xa0, 0xe0, ZC3XX_R006_FRAMEHEIGHTLOW}, /* 00,06,e0,cc, */ + {0xa0, 0x98, ZC3XX_R08B_I2CDEVICEADDR}, /* 00,8b,98,cc, */ + {0xa0, 0x01, ZC3XX_R001_SYSTEMOPERATING}, /* 00,01,01,cc, */ + {0xa0, 0x03, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,03,cc, */ + {0xa0, 0x01, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,01,cc, */ + {0xa0, 0x00, ZC3XX_R098_WINYSTARTLOW}, /* 00,98,00,cc, */ + {0xa0, 0x00, ZC3XX_R09A_WINXSTARTLOW}, /* 00,9a,00,cc, */ + {0xa0, 0x00, ZC3XX_R11A_FIRSTYLOW}, /* 01,1a,00,cc, */ + {0xa0, 0x00, ZC3XX_R11C_FIRSTXLOW}, /* 01,1c,00,cc, */ + {0xa0, 0xe8, ZC3XX_R09C_WINHEIGHTLOW}, /* 00,9c,e8,cc, + * 8<->6 */ + {0xa0, 0x88, ZC3XX_R09E_WINWIDTHLOW}, /* 00,9e,88,cc, + * 8<->6 */ + {0xa0, 0x10, ZC3XX_R087_EXPTIMEMID}, /* 00,87,10,cc, */ + {0xa0, 0x98, ZC3XX_R08B_I2CDEVICEADDR}, /* 00,8b,98,cc, */ {0xaa, 0x1b, 0x0024}, /* 00,1b,24,aa, */ {0xdd, 0x00, 0x0080}, /* 00,00,80,dd, */ {0xaa, 0x1b, 0x0000}, /* 00,1b,00,aa, */ @@ -6039,9 +6056,9 @@ static const struct usb_action tas5130c_vf0250_InitialScale[] = { {0xaa, 0x01, 0x0000}, {0xaa, 0x1a, 0x0000}, /* 00,1a,00,aa, */ {0xaa, 0x1c, 0x0017}, /* 00,1c,17,aa, */ - {0xa0, 0x82, 0x0086}, /* 00,86,82,cc, */ - {0xa0, 0x83, 0x0087}, /* 00,87,83,cc, */ - {0xa0, 0x84, 0x0088}, /* 00,88,84,cc, */ + {0xa0, 0x82, ZC3XX_R086_EXPTIMEHIGH}, /* 00,86,82,cc, */ + {0xa0, 0x83, ZC3XX_R087_EXPTIMEMID}, /* 00,87,83,cc, */ + {0xa0, 0x84, ZC3XX_R088_EXPTIMELOW}, /* 00,88,84,cc, */ {0xaa, 0x05, 0x0010}, /* 00,05,10,aa, */ {0xaa, 0x0a, 0x0000}, /* 00,0a,00,aa, */ {0xaa, 0x0b, 0x00a0}, /* 00,0b,a0,aa, */ @@ -6058,18 +6075,18 @@ static const struct usb_action tas5130c_vf0250_InitialScale[] = { {0xaa, 0x18, 0x0002}, /* 00,18,02,aa, */ {0xaa, 0x19, 0x0088}, /* 00,19,88,aa, */ {0xaa, 0x20, 0x0020}, /* 00,20,20,aa, */ - {0xa0, 0xb7, 0x0101}, /* 01,01,b7,cc, */ - {0xa0, 0x05, 0x0012}, /* 00,12,05,cc, */ - {0xa0, 0x0d, 0x0100}, /* 01,00,0d,cc, */ - {0xa0, 0x76, 0x0189}, /* 01,89,76,cc, */ - {0xa0, 0x09, 0x01ad}, /* 01,ad,09,cc, */ - {0xa0, 0x03, 0x01c5}, /* 01,c5,03,cc, */ - {0xa0, 0x13, 0x01cb}, /* 01,cb,13,cc, */ - {0xa0, 0x08, 0x0250}, /* 02,50,08,cc, */ - {0xa0, 0x08, 0x0301}, /* 03,01,08,cc, */ - {0xa0, 0x60, 0x01a8}, /* 01,a8,60,cc, */ - {0xa0, 0x61, 0x0116}, /* 01,16,61,cc, */ - {0xa0, 0x65, 0x0118}, /* 01,18,65,cc */ + {0xa0, 0xb7, ZC3XX_R101_SENSORCORRECTION}, /* 01,01,b7,cc, */ + {0xa0, 0x05, ZC3XX_R012_VIDEOCONTROLFUNC}, /* 00,12,05,cc, */ + {0xa0, 0x0d, ZC3XX_R100_OPERATIONMODE}, /* 01,00,0d,cc, */ + {0xa0, 0x76, ZC3XX_R189_AWBSTATUS}, /* 01,89,76,cc, */ + {0xa0, 0x09, 0x01ad}, /* 01,ad,09,cc, */ + {0xa0, 0x03, ZC3XX_R1C5_SHARPNESSMODE}, /* 01,c5,03,cc, */ + {0xa0, 0x13, ZC3XX_R1CB_SHARPNESS05}, /* 01,cb,13,cc, */ + {0xa0, 0x08, ZC3XX_R250_DEADPIXELSMODE}, /* 02,50,08,cc, */ + {0xa0, 0x08, ZC3XX_R301_EEPROMACCESS}, /* 03,01,08,cc, */ + {0xa0, 0x60, ZC3XX_R1A8_DIGITALGAIN}, /* 01,a8,60,cc, */ + {0xa0, 0x61, ZC3XX_R116_RGAIN}, /* 01,16,61,cc, */ + {0xa0, 0x65, ZC3XX_R118_BGAIN}, /* 01,18,65,cc */ {} }; /* "50HZ" light frequency banding filter */ @@ -6077,23 +6094,23 @@ static const struct usb_action tas5130c_vf0250_50HZ[] = { {0xaa, 0x82, 0x0000}, /* 00,82,00,aa */ {0xaa, 0x83, 0x0001}, /* 00,83,01,aa */ {0xaa, 0x84, 0x00aa}, /* 00,84,aa,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc, */ - {0xa0, 0x06, 0x0191}, /* 01,91,0d,cc, */ - {0xa0, 0xa8, 0x0192}, /* 01,92,50,cc, */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc, */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc, */ - {0xa0, 0x8e, 0x0197}, /* 01,97,47,cc, */ - {0xa0, 0x0e, 0x018c}, /* 01,8c,0e,cc, */ - {0xa0, 0x15, 0x018f}, /* 01,8f,15,cc, */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc, */ - {0xa0, 0x24, 0x01aa}, /* 01,aa,24,cc, */ - {0xa0, 0x62, 0x001d}, /* 00,1d,62,cc, */ - {0xa0, 0x90, 0x001e}, /* 00,1e,90,cc, */ - {0xa0, 0xc8, 0x001f}, /* 00,1f,c8,cc, */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc, */ - {0xa0, 0x58, 0x011d}, /* 01,1d,58,cc, */ - {0xa0, 0x42, 0x0180}, /* 01,80,42,cc, */ - {0xa0, 0x78, 0x018d}, /* 01,8d,78,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc, */ + {0xa0, 0x06, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,0d,cc, */ + {0xa0, 0xa8, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,50,cc, */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc, */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc, */ + {0xa0, 0x8e, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,47,cc, */ + {0xa0, 0x0e, ZC3XX_R18C_AEFREEZE}, /* 01,8c,0e,cc, */ + {0xa0, 0x15, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,15,cc, */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc, */ + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,24,cc, */ + {0xa0, 0x62, ZC3XX_R01D_HSYNC_0}, /* 00,1d,62,cc, */ + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, /* 00,1e,90,cc, */ + {0xa0, 0xc8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,c8,cc, */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc, */ + {0xa0, 0x58, ZC3XX_R11D_GLOBALGAIN}, /* 01,1d,58,cc, */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,42,cc, */ + {0xa0, 0x78, ZC3XX_R18D_YTARGET}, /* 01,8d,78,cc */ {} }; @@ -6102,23 +6119,23 @@ static const struct usb_action tas5130c_vf0250_50HZScale[] = { {0xaa, 0x82, 0x0000}, /* 00,82,00,aa */ {0xaa, 0x83, 0x0003}, /* 00,83,03,aa */ {0xaa, 0x84, 0x0054}, /* 00,84,54,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc, */ - {0xa0, 0x0d, 0x0191}, /* 01,91,0d,cc, */ - {0xa0, 0x50, 0x0192}, /* 01,92,50,cc, */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc, */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc, */ - {0xa0, 0x8e, 0x0197}, /* 01,97,8e,cc, */ - {0xa0, 0x0e, 0x018c}, /* 01,8c,0e,cc, */ - {0xa0, 0x15, 0x018f}, /* 01,8f,15,cc, */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc, */ - {0xa0, 0x24, 0x01aa}, /* 01,aa,24,cc, */ - {0xa0, 0x62, 0x001d}, /* 00,1d,62,cc, */ - {0xa0, 0x90, 0x001e}, /* 00,1e,90,cc, */ - {0xa0, 0xc8, 0x001f}, /* 00,1f,c8,cc, */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc, */ - {0xa0, 0x58, 0x011d}, /* 01,1d,58,cc, */ - {0xa0, 0x42, 0x0180}, /* 01,80,42,cc, */ - {0xa0, 0x78, 0x018d}, /* 01,8d,78,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc, */ + {0xa0, 0x0d, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,0d,cc, */ + {0xa0, 0x50, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,50,cc, */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc, */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc, */ + {0xa0, 0x8e, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,8e,cc, */ + {0xa0, 0x0e, ZC3XX_R18C_AEFREEZE}, /* 01,8c,0e,cc, */ + {0xa0, 0x15, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,15,cc, */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc, */ + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,24,cc, */ + {0xa0, 0x62, ZC3XX_R01D_HSYNC_0}, /* 00,1d,62,cc, */ + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, /* 00,1e,90,cc, */ + {0xa0, 0xc8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,c8,cc, */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc, */ + {0xa0, 0x58, ZC3XX_R11D_GLOBALGAIN}, /* 01,1d,58,cc, */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,42,cc, */ + {0xa0, 0x78, ZC3XX_R18D_YTARGET}, /* 01,8d,78,cc */ {} }; @@ -6127,23 +6144,23 @@ static const struct usb_action tas5130c_vf0250_60HZ[] = { {0xaa, 0x82, 0x0000}, /* 00,82,00,aa */ {0xaa, 0x83, 0x0001}, /* 00,83,01,aa */ {0xaa, 0x84, 0x0062}, /* 00,84,62,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc, */ - {0xa0, 0x05, 0x0191}, /* 01,91,05,cc, */ - {0xa0, 0x88, 0x0192}, /* 01,92,88,cc, */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc, */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc, */ - {0xa0, 0x3b, 0x0197}, /* 01,97,3b,cc, */ - {0xa0, 0x0e, 0x018c}, /* 01,8c,0e,cc, */ - {0xa0, 0x15, 0x018f}, /* 01,8f,15,cc, */ - {0xa0, 0x10, 0x01a9}, /* 01,a9,10,cc, */ - {0xa0, 0x24, 0x01aa}, /* 01,aa,24,cc, */ - {0xa0, 0x62, 0x001d}, /* 00,1d,62,cc, */ - {0xa0, 0x90, 0x001e}, /* 00,1e,90,cc, */ - {0xa0, 0xc8, 0x001f}, /* 00,1f,c8,cc, */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc, */ - {0xa0, 0x58, 0x011d}, /* 01,1d,58,cc, */ - {0xa0, 0x42, 0x0180}, /* 01,80,42,cc, */ - {0xa0, 0x78, 0x018d}, /* 01,8d,78,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc, */ + {0xa0, 0x05, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,05,cc, */ + {0xa0, 0x88, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,88,cc, */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc, */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc, */ + {0xa0, 0x3b, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,3b,cc, */ + {0xa0, 0x0e, ZC3XX_R18C_AEFREEZE}, /* 01,8c,0e,cc, */ + {0xa0, 0x15, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,15,cc, */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,a9,10,cc, */ + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,aa,24,cc, */ + {0xa0, 0x62, ZC3XX_R01D_HSYNC_0}, /* 00,1d,62,cc, */ + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, /* 00,1e,90,cc, */ + {0xa0, 0xc8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,c8,cc, */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc, */ + {0xa0, 0x58, ZC3XX_R11D_GLOBALGAIN}, /* 01,1d,58,cc, */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,42,cc, */ + {0xa0, 0x78, ZC3XX_R18D_YTARGET}, /* 01,8d,78,cc */ {} }; @@ -6152,89 +6169,93 @@ static const struct usb_action tas5130c_vf0250_60HZScale[] = { {0xaa, 0x82, 0x0000}, /* 00,82,00,aa */ {0xaa, 0x83, 0x0002}, /* 00,83,02,aa */ {0xaa, 0x84, 0x00c4}, /* 00,84,c4,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc, */ - {0xa0, 0x0b, 0x0191}, /* 01,1,0b,cc, */ - {0xa0, 0x10, 0x0192}, /* 01,2,10,cc, */ - {0xa0, 0x00, 0x0195}, /* 01,5,00,cc, */ - {0xa0, 0x00, 0x0196}, /* 01,6,00,cc, */ - {0xa0, 0x76, 0x0197}, /* 01,7,76,cc, */ - {0xa0, 0x0e, 0x018c}, /* 01,c,0e,cc, */ - {0xa0, 0x15, 0x018f}, /* 01,f,15,cc, */ - {0xa0, 0x10, 0x01a9}, /* 01,9,10,cc, */ - {0xa0, 0x24, 0x01aa}, /* 01,a,24,cc, */ - {0xa0, 0x62, 0x001d}, /* 00,d,62,cc, */ - {0xa0, 0x90, 0x001e}, /* 00,e,90,cc, */ - {0xa0, 0xc8, 0x001f}, /* 00,f,c8,cc, */ - {0xa0, 0xff, 0x0020}, /* 00,0,ff,cc, */ - {0xa0, 0x58, 0x011d}, /* 01,d,58,cc, */ - {0xa0, 0x42, 0x0180}, /* 01,80,42,cc, */ - {0xa0, 0x78, 0x018d}, /* 01,d,78,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc, */ + {0xa0, 0x0b, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,1,0b,cc, */ + {0xa0, 0x10, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,2,10,cc, */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,5,00,cc, */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,6,00,cc, */ + {0xa0, 0x76, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,7,76,cc, */ + {0xa0, 0x0e, ZC3XX_R18C_AEFREEZE}, /* 01,c,0e,cc, */ + {0xa0, 0x15, ZC3XX_R18F_AEUNFREEZE}, /* 01,f,15,cc, */ + {0xa0, 0x10, ZC3XX_R1A9_DIGITALLIMITDIFF}, /* 01,9,10,cc, */ + {0xa0, 0x24, ZC3XX_R1AA_DIGITALGAINSTEP}, /* 01,a,24,cc, */ + {0xa0, 0x62, ZC3XX_R01D_HSYNC_0}, /* 00,d,62,cc, */ + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, /* 00,e,90,cc, */ + {0xa0, 0xc8, ZC3XX_R01F_HSYNC_2}, /* 00,f,c8,cc, */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,0,ff,cc, */ + {0xa0, 0x58, ZC3XX_R11D_GLOBALGAIN}, /* 01,d,58,cc, */ + {0xa0, 0x42, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,42,cc, */ + {0xa0, 0x78, ZC3XX_R18D_YTARGET}, /* 01,d,78,cc */ {} }; /* "NoFliker" light frequency banding flter */ static const struct usb_action tas5130c_vf0250_NoFliker[] = { - {0xa0, 0x0c, 0x0100}, /* 01,00,0c,cc, */ + {0xa0, 0x0c, ZC3XX_R100_OPERATIONMODE}, /* 01,00,0c,cc, */ {0xaa, 0x82, 0x0000}, /* 00,82,00,aa */ {0xaa, 0x83, 0x0000}, /* 00,83,00,aa */ {0xaa, 0x84, 0x0020}, /* 00,84,20,aa */ - {0xa0, 0x00, 0x0190}, /* 01,0,00,cc, */ - {0xa0, 0x05, 0x0191}, /* 01,91,05,cc, */ - {0xa0, 0x88, 0x0192}, /* 01,92,88,cc, */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc, */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc, */ - {0xa0, 0x10, 0x0197}, /* 01,97,10,cc, */ - {0xa0, 0x0e, 0x018c}, /* 01,8c,0e,cc, */ - {0xa0, 0x15, 0x018f}, /* 01,8f,15,cc, */ - {0xa0, 0x62, 0x001d}, /* 00,1d,62,cc, */ - {0xa0, 0x90, 0x001e}, /* 00,1e,90,cc, */ - {0xa0, 0xc8, 0x001f}, /* 00,1f,c8,cc, */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc, */ - {0xa0, 0x58, 0x011d}, /* 01,1d,58,cc, */ - {0xa0, 0x03, 0x0180}, /* 01,80,03,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,0,00,cc, */ + {0xa0, 0x05, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,05,cc, */ + {0xa0, 0x88, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,88,cc, */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc, */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc, */ + {0xa0, 0x10, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,10,cc, */ + {0xa0, 0x0e, ZC3XX_R18C_AEFREEZE}, /* 01,8c,0e,cc, */ + {0xa0, 0x15, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,15,cc, */ + {0xa0, 0x62, ZC3XX_R01D_HSYNC_0}, /* 00,1d,62,cc, */ + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, /* 00,1e,90,cc, */ + {0xa0, 0xc8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,c8,cc, */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc, */ + {0xa0, 0x58, ZC3XX_R11D_GLOBALGAIN}, /* 01,1d,58,cc, */ + {0xa0, 0x03, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,03,cc */ {} }; /* "NoFlikerScale" light frequency banding filter */ static const struct usb_action tas5130c_vf0250_NoFlikerScale[] = { - {0xa0, 0x0c, 0x0100}, /* 01,00,0c,cc, */ + {0xa0, 0x0c, ZC3XX_R100_OPERATIONMODE}, /* 01,00,0c,cc, */ {0xaa, 0x82, 0x0000}, /* 00,82,00,aa */ {0xaa, 0x83, 0x0000}, /* 00,83,00,aa */ {0xaa, 0x84, 0x0020}, /* 00,84,20,aa */ - {0xa0, 0x00, 0x0190}, /* 01,90,00,cc, */ - {0xa0, 0x0b, 0x0191}, /* 01,91,0b,cc, */ - {0xa0, 0x10, 0x0192}, /* 01,92,10,cc, */ - {0xa0, 0x00, 0x0195}, /* 01,95,00,cc, */ - {0xa0, 0x00, 0x0196}, /* 01,96,00,cc, */ - {0xa0, 0x10, 0x0197}, /* 01,97,10,cc, */ - {0xa0, 0x0e, 0x018c}, /* 01,8c,0e,cc, */ - {0xa0, 0x15, 0x018f}, /* 01,8f,15,cc, */ - {0xa0, 0x62, 0x001d}, /* 00,1d,62,cc, */ - {0xa0, 0x90, 0x001e}, /* 00,1e,90,cc, */ - {0xa0, 0xc8, 0x001f}, /* 00,1f,c8,cc, */ - {0xa0, 0xff, 0x0020}, /* 00,20,ff,cc, */ - {0xa0, 0x58, 0x011d}, /* 01,1d,58,cc, */ - {0xa0, 0x03, 0x0180}, /* 01,80,03,cc */ + {0xa0, 0x00, ZC3XX_R190_EXPOSURELIMITHIGH}, /* 01,90,00,cc, */ + {0xa0, 0x0b, ZC3XX_R191_EXPOSURELIMITMID}, /* 01,91,0b,cc, */ + {0xa0, 0x10, ZC3XX_R192_EXPOSURELIMITLOW}, /* 01,92,10,cc, */ + {0xa0, 0x00, ZC3XX_R195_ANTIFLICKERHIGH}, /* 01,95,00,cc, */ + {0xa0, 0x00, ZC3XX_R196_ANTIFLICKERMID}, /* 01,96,00,cc, */ + {0xa0, 0x10, ZC3XX_R197_ANTIFLICKERLOW}, /* 01,97,10,cc, */ + {0xa0, 0x0e, ZC3XX_R18C_AEFREEZE}, /* 01,8c,0e,cc, */ + {0xa0, 0x15, ZC3XX_R18F_AEUNFREEZE}, /* 01,8f,15,cc, */ + {0xa0, 0x62, ZC3XX_R01D_HSYNC_0}, /* 00,1d,62,cc, */ + {0xa0, 0x90, ZC3XX_R01E_HSYNC_1}, /* 00,1e,90,cc, */ + {0xa0, 0xc8, ZC3XX_R01F_HSYNC_2}, /* 00,1f,c8,cc, */ + {0xa0, 0xff, ZC3XX_R020_HSYNC_3}, /* 00,20,ff,cc, */ + {0xa0, 0x58, ZC3XX_R11D_GLOBALGAIN}, /* 01,1d,58,cc, */ + {0xa0, 0x03, ZC3XX_R180_AUTOCORRECTENABLE}, /* 01,80,03,cc */ {} }; -static void reg_r_i(struct usb_device *dev, - __u16 index, __u8 *buffer) +static int reg_r_i(struct gspca_dev *gspca_dev, + __u16 index) { - usb_control_msg(dev, - usb_rcvctrlpipe(dev, 0), + usb_control_msg(gspca_dev->dev, + usb_rcvctrlpipe(gspca_dev->dev, 0), 0xa1, USB_DIR_IN | USB_TYPE_VENDOR | USB_RECIP_DEVICE, 0x01, /* value */ - index, buffer, 1, + index, gspca_dev->usb_buf, 1, 500); + return gspca_dev->usb_buf[0]; } -static void reg_r(struct usb_device *dev, - __u16 index, __u8 *buffer) +static int reg_r(struct gspca_dev *gspca_dev, + __u16 index) { - reg_r_i(dev, index, buffer); - PDEBUG(D_USBI, "reg r [%04x] -> %02x", index, *buffer); + int ret; + + ret = reg_r_i(gspca_dev, index); + PDEBUG(D_USBI, "reg r [%04x] -> %02x", index, ret); + return ret; } static void reg_w_i(struct usb_device *dev, @@ -6253,59 +6274,58 @@ static void reg_w(struct usb_device *dev, __u8 value, __u16 index) { - PDEBUG(D_USBO, "reg w %02x -> [%04x]", value, index); + PDEBUG(D_USBO, "reg w [%04x] = %02x", index, value); reg_w_i(dev, value, index); } -static __u16 i2c_read(struct usb_device *dev, __u8 reg) +static __u16 i2c_read(struct gspca_dev *gspca_dev, + __u8 reg) { __u8 retbyte; - __u8 retval[2]; + __u16 retval; - reg_w_i(dev, reg, 0x92); - reg_w_i(dev, 0x02, 0x90); /* <- read command */ + reg_w_i(gspca_dev->dev, reg, 0x92); + reg_w_i(gspca_dev->dev, 0x02, 0x90); /* <- read command */ msleep(25); - reg_r_i(dev, 0x0091, &retbyte); /* read status */ - reg_r_i(dev, 0x0095, &retval[0]); /* read Lowbyte */ - reg_r_i(dev, 0x0096, &retval[1]); /* read Hightbyte */ - PDEBUG(D_USBO, "i2c r [%02x] -> (%02x) %02x%02x", - reg, retbyte, retval[1], retval[0]); - return (retval[1] << 8) | retval[0]; + retbyte = reg_r_i(gspca_dev, 0x0091); /* read status */ + retval = reg_r_i(gspca_dev, 0x0095); /* read Lowbyte */ + retval |= reg_r_i(gspca_dev, 0x0096) << 8; /* read Hightbyte */ + PDEBUG(D_USBO, "i2c r [%02x] -> %04x (%02x)", + reg, retval, retbyte); + return retval; } -static __u8 i2c_write(struct usb_device *dev, +static __u8 i2c_write(struct gspca_dev *gspca_dev, __u8 reg, __u8 valL, __u8 valH) { __u8 retbyte; - reg_w_i(dev, reg, 0x92); - reg_w_i(dev, valL, 0x93); - reg_w_i(dev, valH, 0x94); - reg_w_i(dev, 0x01, 0x90); /* <- write command */ + reg_w_i(gspca_dev->dev, reg, 0x92); + reg_w_i(gspca_dev->dev, valL, 0x93); + reg_w_i(gspca_dev->dev, valH, 0x94); + reg_w_i(gspca_dev->dev, 0x01, 0x90); /* <- write command */ msleep(5); - reg_r_i(dev, 0x0091, &retbyte); /* read status */ - PDEBUG(D_USBO, "i2c w [%02x] %02x%02x (%02x)", + retbyte = reg_r_i(gspca_dev, 0x0091); /* read status */ + PDEBUG(D_USBO, "i2c w [%02x] = %02x%02x (%02x)", reg, valH, valL, retbyte); return retbyte; } -static void usb_exchange(struct usb_device *dev, +static void usb_exchange(struct gspca_dev *gspca_dev, const struct usb_action *action) { - __u8 buffread; - while (action->req) { switch (action->req) { case 0xa0: /* write register */ - reg_w(dev, action->val, action->idx); + reg_w(gspca_dev->dev, action->val, action->idx); break; case 0xa1: /* read status */ - reg_r(dev, action->idx, &buffread); + reg_r(gspca_dev, action->idx); break; case 0xaa: - i2c_write(dev, + i2c_write(gspca_dev, action->val, /* reg */ action->idx & 0xff, /* valL */ action->idx >> 8); /* valH */ @@ -6331,6 +6351,8 @@ static void setmatrix(struct gspca_dev *gspca_dev) {0x58, 0xf4, 0xf4, 0xf4, 0x58, 0xf4, 0xf4, 0xf4, 0x58}; static const __u8 po2030_matrix[9] = {0x60, 0xf0, 0xf0, 0xf0, 0x60, 0xf0, 0xf0, 0xf0, 0x60}; + static const __u8 vf0250_matrix[9] = + {0x7b, 0xea, 0xea, 0xea, 0x7b, 0xea, 0xea, 0xea, 0x7b}; switch (sd->sensor) { case SENSOR_GC0305: @@ -6345,8 +6367,9 @@ static void setmatrix(struct gspca_dev *gspca_dev) case SENSOR_PO2030: matrix = po2030_matrix; break; - case SENSOR_TAS5130C_VF0250: /* no matrix? */ - return; + case SENSOR_TAS5130C_VF0250: + matrix = vf0250_matrix; + break; default: /* matrix already loaded */ return; } @@ -6380,7 +6403,6 @@ static void setsharpness(struct gspca_dev *gspca_dev) struct sd *sd = (struct sd *) gspca_dev; struct usb_device *dev = gspca_dev->dev; int sharpness; - __u8 retbyte; static const __u8 sharpness_tb[][2] = { {0x02, 0x03}, {0x04, 0x07}, @@ -6390,9 +6412,9 @@ static void setsharpness(struct gspca_dev *gspca_dev) sharpness = sd->sharpness; reg_w(dev, sharpness_tb[sharpness][0], 0x01c6); - reg_r(dev, 0x01c8, &retbyte); - reg_r(dev, 0x01c9, &retbyte); - reg_r(dev, 0x01ca, &retbyte); + reg_r(gspca_dev, 0x01c8); + reg_r(gspca_dev, 0x01c9); + reg_r(gspca_dev, 0x01ca); reg_w(dev, sharpness_tb[sharpness][1], 0x01cb); } @@ -6402,7 +6424,7 @@ static void setcontrast(struct gspca_dev *gspca_dev) struct usb_device *dev = gspca_dev->dev; const __u8 *Tgamma, *Tgradient; int g, i, k; - static const __u8 kgamma_tb[16] = /* delta for contrast */ + static const __u8 kgamma_tb[16] = /* delta for contrast */ {0x15, 0x0d, 0x0a, 0x09, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08}; static const __u8 kgrad_tb[16] = @@ -6627,7 +6649,7 @@ static int setlightfreq(struct gspca_dev *gspca_dev) i++; /* 640x480 */ zc3_freq = freq_tb[(int) sd->sensor][i]; if (zc3_freq != NULL) { - usb_exchange(gspca_dev->dev, zc3_freq); + usb_exchange(gspca_dev, zc3_freq); switch (sd->sensor) { case SENSOR_GC0305: if (mode /* if 320x240 */ @@ -6691,44 +6713,45 @@ static void start_2wr_probe(struct usb_device *dev, int sensor) /* msleep(2); */ } -static int sif_probe(struct usb_device *dev) +static int sif_probe(struct gspca_dev *gspca_dev) { __u16 checkword; - start_2wr_probe(dev, 0x0f); /* PAS106 */ - reg_w(dev, 0x08, 0x008d); + start_2wr_probe(gspca_dev->dev, 0x0f); /* PAS106 */ + reg_w(gspca_dev->dev, 0x08, 0x008d); msleep(150); - checkword = ((i2c_read(dev, 0x00) & 0x0f) << 4) - | ((i2c_read(dev, 0x01) & 0xf0) >> 4); + checkword = ((i2c_read(gspca_dev, 0x00) & 0x0f) << 4) + | ((i2c_read(gspca_dev, 0x01) & 0xf0) >> 4); PDEBUG(D_PROBE, "probe sif 0x%04x", checkword); if (checkword == 0x0007) { - send_unknown(dev, SENSOR_PAS106); + send_unknown(gspca_dev->dev, SENSOR_PAS106); return 0x0f; /* PAS106 */ } return -1; } -static int vga_2wr_probe(struct usb_device *dev) +static int vga_2wr_probe(struct gspca_dev *gspca_dev) { + struct usb_device *dev = gspca_dev->dev; __u8 retbyte; __u16 checkword; start_2wr_probe(dev, 0x00); /* HV7131B */ - i2c_write(dev, 0x01, 0xaa, 0x00); - retbyte = i2c_read(dev, 0x01); + i2c_write(gspca_dev, 0x01, 0xaa, 0x00); + retbyte = i2c_read(gspca_dev, 0x01); if (retbyte != 0) return 0x00; /* HV7131B */ start_2wr_probe(dev, 0x04); /* CS2102 */ - i2c_write(dev, 0x01, 0xaa, 0x00); - retbyte = i2c_read(dev, 0x01); + i2c_write(gspca_dev, 0x01, 0xaa, 0x00); + retbyte = i2c_read(gspca_dev, 0x01); if (retbyte != 0) return 0x04; /* CS2102 */ start_2wr_probe(dev, 0x06); /* OmniVision */ - reg_w(dev, 0x08, 0x8d); - i2c_write(dev, 0x11, 0xaa, 0x00); - retbyte = i2c_read(dev, 0x11); + reg_w(dev, 0x08, 0x008d); + i2c_write(gspca_dev, 0x11, 0xaa, 0x00); + retbyte = i2c_read(gspca_dev, 0x11); if (retbyte != 0) { /* (should have returned 0xaa) --> Omnivision? */ /* reg_r 0x10 -> 0x06 --> */ @@ -6736,45 +6759,45 @@ static int vga_2wr_probe(struct usb_device *dev) } start_2wr_probe(dev, 0x08); /* HDCS2020 */ - i2c_write(dev, 0x15, 0xaa, 0x00); - retbyte = i2c_read(dev, 0x15); + i2c_write(gspca_dev, 0x15, 0xaa, 0x00); + retbyte = i2c_read(gspca_dev, 0x15); if (retbyte != 0) return 0x08; /* HDCS2020 */ start_2wr_probe(dev, 0x0a); /* PB0330 */ - i2c_write(dev, 0x07, 0xaa, 0xaa); - retbyte = i2c_read(dev, 0x07); + i2c_write(gspca_dev, 0x07, 0xaa, 0xaa); + retbyte = i2c_read(gspca_dev, 0x07); if (retbyte != 0) return 0x0a; /* PB0330 */ - retbyte = i2c_read(dev, 0x03); + retbyte = i2c_read(gspca_dev, 0x03); if (retbyte != 0) return 0x0a; /* PB0330 ?? */ - retbyte = i2c_read(dev, 0x04); + retbyte = i2c_read(gspca_dev, 0x04); if (retbyte != 0) return 0x0a; /* PB0330 ?? */ start_2wr_probe(dev, 0x0c); /* ICM105A */ - i2c_write(dev, 0x01, 0x11, 0x00); - retbyte = i2c_read(dev, 0x01); + i2c_write(gspca_dev, 0x01, 0x11, 0x00); + retbyte = i2c_read(gspca_dev, 0x01); if (retbyte != 0) return 0x0c; /* ICM105A */ start_2wr_probe(dev, 0x0e); /* PAS202BCB */ - reg_w(dev, 0x08, 0x8d); - i2c_write(dev, 0x03, 0xaa, 0x00); + reg_w(dev, 0x08, 0x008d); + i2c_write(gspca_dev, 0x03, 0xaa, 0x00); msleep(500); - retbyte = i2c_read(dev, 0x03); + retbyte = i2c_read(gspca_dev, 0x03); if (retbyte != 0) return 0x0e; /* PAS202BCB */ start_2wr_probe(dev, 0x02); /* ?? */ - i2c_write(dev, 0x01, 0xaa, 0x00); - retbyte = i2c_read(dev, 0x01); + i2c_write(gspca_dev, 0x01, 0xaa, 0x00); + retbyte = i2c_read(gspca_dev, 0x01); if (retbyte != 0) return 0x02; /* ?? */ ov_check: - reg_r(dev, 0x0010, &retbyte); /* ?? */ - reg_r(dev, 0x0010, &retbyte); + reg_r(gspca_dev, 0x0010); /* ?? */ + reg_r(gspca_dev, 0x0010); reg_w(dev, 0x01, 0x0000); reg_w(dev, 0x01, 0x0001); @@ -6783,10 +6806,10 @@ ov_check: reg_w(dev, 0x08, 0x008d); msleep(500); reg_w(dev, 0x01, 0x0012); - i2c_write(dev, 0x12, 0x80, 0x00); /* sensor reset */ - retbyte = i2c_read(dev, 0x0a); + i2c_write(gspca_dev, 0x12, 0x80, 0x00); /* sensor reset */ + retbyte = i2c_read(gspca_dev, 0x0a); checkword = retbyte << 8; - retbyte = i2c_read(dev, 0x0b); + retbyte = i2c_read(gspca_dev, 0x0b); checkword |= retbyte; PDEBUG(D_PROBE, "probe 2wr ov vga 0x%04x", checkword); switch (checkword) { @@ -6812,7 +6835,6 @@ static const struct sensor_by_chipset_revision chipset_revision_sensor[] = { {0x8001, 0x13}, {0x8000, 0x14}, /* CS2102K */ {0x8400, 0x15}, /* TAS5130K */ - {0, 0} }; static int vga_3wr_probe(struct gspca_dev *gspca_dev) @@ -6825,7 +6847,7 @@ static int vga_3wr_probe(struct gspca_dev *gspca_dev) /*fixme: lack of 8b=b3 (11,12)-> 10, 8b=e0 (14,15,16)-> 12 found in gspcav1*/ reg_w(dev, 0x02, 0x0010); - reg_r(dev, 0x10, &retbyte); + reg_r(gspca_dev, 0x0010); reg_w(dev, 0x01, 0x0000); reg_w(dev, 0x00, 0x0010); reg_w(dev, 0x01, 0x0001); @@ -6833,41 +6855,39 @@ static int vga_3wr_probe(struct gspca_dev *gspca_dev) reg_w(dev, 0x03, 0x0012); reg_w(dev, 0x01, 0x0012); reg_w(dev, 0x05, 0x0012); - retbyte = i2c_read(dev, 0x14); + retbyte = i2c_read(gspca_dev, 0x14); if (retbyte != 0) return 0x11; /* HV7131R */ - retbyte = i2c_read(dev, 0x15); + retbyte = i2c_read(gspca_dev, 0x15); if (retbyte != 0) return 0x11; /* HV7131R */ - retbyte = i2c_read(dev, 0x16); + retbyte = i2c_read(gspca_dev, 0x16); if (retbyte != 0) return 0x11; /* HV7131R */ reg_w(dev, 0x02, 0x0010); - reg_r(dev, 0x000b, &retbyte); + retbyte = reg_r(gspca_dev, 0x000b); checkword = retbyte << 8; - reg_r(dev, 0x000a, &retbyte); + retbyte = reg_r(gspca_dev, 0x000a); checkword |= retbyte; PDEBUG(D_PROBE, "probe 3wr vga 1 0x%04x", checkword); - reg_r(dev, 0x0010, &retbyte); + reg_r(gspca_dev, 0x0010); /* this is tested only once anyway */ - i = 0; - while (chipset_revision_sensor[i].revision) { + for (i = 0; i < ARRAY_SIZE(chipset_revision_sensor); i++) { if (chipset_revision_sensor[i].revision == checkword) { sd->chip_revision = checkword; send_unknown(dev, SENSOR_PB0330); return chipset_revision_sensor[i].internal_sensor_id; } - i++; } - reg_w(dev, 0x01, 0x0000); + reg_w(dev, 0x01, 0x0000); /* check ?? */ reg_w(dev, 0x01, 0x0001); reg_w(dev, 0xdd, 0x008b); reg_w(dev, 0x0a, 0x0010); reg_w(dev, 0x03, 0x0012); reg_w(dev, 0x01, 0x0012); - retbyte = i2c_read(dev, 0x00); + retbyte = i2c_read(gspca_dev, 0x00); if (retbyte != 0) { PDEBUG(D_PROBE, "probe 3wr vga type 0a ?"); return 0x0a; /* ?? */ @@ -6880,11 +6900,14 @@ static int vga_3wr_probe(struct gspca_dev *gspca_dev) reg_w(dev, 0x03, 0x0012); msleep(2); reg_w(dev, 0x01, 0x0012); - retbyte = i2c_read(dev, 0x00); + retbyte = i2c_read(gspca_dev, 0x00); if (retbyte != 0) { PDEBUG(D_PROBE, "probe 3wr vga type %02x", retbyte); - send_unknown(dev, SENSOR_GC0305); - return retbyte; /* 0x29 = gc0305 - should continue? */ + if (retbyte == 0x11) /* VF0250 */ + return 0x0250; + if (retbyte == 0x29) /* gc0305 */ + send_unknown(dev, SENSOR_GC0305); + return retbyte; } reg_w(dev, 0x01, 0x0000); /* check OmniVision */ @@ -6894,42 +6917,42 @@ static int vga_3wr_probe(struct gspca_dev *gspca_dev) reg_w(dev, 0x06, 0x0010); reg_w(dev, 0x01, 0x0012); reg_w(dev, 0x05, 0x0012); - if (i2c_read(dev, 0x1c) == 0x7f /* OV7610 - manufacturer ID */ - && i2c_read(dev, 0x1d) == 0xa2) { + if (i2c_read(gspca_dev, 0x1c) == 0x7f /* OV7610 - manufacturer ID */ + && i2c_read(gspca_dev, 0x1d) == 0xa2) { send_unknown(dev, SENSOR_OV7620); return 0x06; /* OmniVision confirm ? */ } - reg_w(dev, 0x01, 0x00); - reg_w(dev, 0x00, 0x02); - reg_w(dev, 0x01, 0x10); - reg_w(dev, 0x01, 0x01); - reg_w(dev, 0xee, 0x8b); - reg_w(dev, 0x03, 0x12); + reg_w(dev, 0x01, 0x0000); + reg_w(dev, 0x00, 0x0002); + reg_w(dev, 0x01, 0x0010); + reg_w(dev, 0x01, 0x0001); + reg_w(dev, 0xee, 0x008b); + reg_w(dev, 0x03, 0x0012); /* msleep(150); */ - reg_w(dev, 0x01, 0x12); - reg_w(dev, 0x05, 0x12); - retbyte = i2c_read(dev, 0x00); /* ID 0 */ + reg_w(dev, 0x01, 0x0012); + reg_w(dev, 0x05, 0x0012); + retbyte = i2c_read(gspca_dev, 0x0000); /* ID 0 */ checkword = retbyte << 8; - retbyte = i2c_read(dev, 0x01); /* ID 1 */ + retbyte = i2c_read(gspca_dev, 0x0001); /* ID 1 */ checkword |= retbyte; PDEBUG(D_PROBE, "probe 3wr vga 2 0x%04x", checkword); if (checkword == 0x2030) { - retbyte = i2c_read(dev, 0x02); /* revision number */ + retbyte = i2c_read(gspca_dev, 0x02); /* revision number */ PDEBUG(D_PROBE, "sensor PO2030 rev 0x%02x", retbyte); send_unknown(dev, SENSOR_PO2030); return checkword; } - reg_w(dev, 0x01, 0x00); - reg_w(dev, 0x0a, 0x10); - reg_w(dev, 0xd3, 0x8b); - reg_w(dev, 0x01, 0x01); - reg_w(dev, 0x03, 0x12); - reg_w(dev, 0x01, 0x12); - reg_w(dev, 0x05, 0x01); - reg_w(dev, 0xd3, 0x8b); - retbyte = i2c_read(dev, 0x01); + reg_w(dev, 0x01, 0x0000); + reg_w(dev, 0x0a, 0x0010); + reg_w(dev, 0xd3, 0x008b); + reg_w(dev, 0x01, 0x0001); + reg_w(dev, 0x03, 0x0012); + reg_w(dev, 0x01, 0x0012); + reg_w(dev, 0x05, 0x0001); + reg_w(dev, 0xd3, 0x008b); + retbyte = i2c_read(gspca_dev, 0x01); if (retbyte != 0) { PDEBUG(D_PROBE, "probe 3wr vga type 0a ?"); return 0x0a; /* ?? */ @@ -6940,15 +6963,16 @@ static int vga_3wr_probe(struct gspca_dev *gspca_dev) static int zcxx_probeSensor(struct gspca_dev *gspca_dev) { struct sd *sd = (struct sd *) gspca_dev; - struct usb_device *dev = gspca_dev->dev; int sensor, sensor2; switch (sd->sensor) { case SENSOR_MC501CB: + return -1; /* don't probe */ case SENSOR_TAS5130C_VF0250: + /* may probe but with write in reg 0x0010 */ return -1; /* don't probe */ } - sensor = vga_2wr_probe(dev); + sensor = vga_2wr_probe(gspca_dev); if (sensor >= 0) { if (sensor < 0x7600) return sensor; @@ -6960,7 +6984,7 @@ static int zcxx_probeSensor(struct gspca_dev *gspca_dev) return sensor; return sensor2; } - return sif_probe(dev); + return sif_probe(gspca_dev); } /* this function is called at probe time */ @@ -6970,7 +6994,6 @@ static int sd_config(struct gspca_dev *gspca_dev, struct sd *sd = (struct sd *) gspca_dev; struct cam *cam; int sensor; - __u8 bsensor; int vga = 1; /* 1: vga, 0: sif */ static const __u8 gamma[SENSOR_MAX] = { 5, /* SENSOR_CS2102 0 */ @@ -6994,6 +7017,7 @@ static int sd_config(struct gspca_dev *gspca_dev, /* define some sensors from the vendor/product */ sd->sharpness = 2; + sd->sensor = -1; switch (id->idVendor) { case 0x041e: /* Creative */ switch (id->idProduct) { @@ -7103,6 +7127,10 @@ static int sd_config(struct gspca_dev *gspca_dev, PDEBUG(D_PROBE, "Find Sensor GC0305"); sd->sensor = SENSOR_GC0305; break; + case 0x0250: + PDEBUG(D_PROBE, "Sensor Tas5130 (VF0250)"); + sd->sensor = SENSOR_TAS5130C_VF0250; + break; case 0x2030: PDEBUG(D_PROBE, "Find Sensor PO2030"); sd->sensor = SENSOR_PO2030; @@ -7126,7 +7154,7 @@ static int sd_config(struct gspca_dev *gspca_dev, reg_w(gspca_dev->dev, 0x02, 0x0010); else reg_w(gspca_dev->dev, sensor & 0x0f, 0x0010); - reg_r(gspca_dev->dev, 0x0010, &bsensor); + reg_r(gspca_dev, 0x0010); } cam = &gspca_dev->cam; @@ -7167,7 +7195,6 @@ static void sd_start(struct gspca_dev *gspca_dev) struct usb_device *dev = gspca_dev->dev; const struct usb_action *zc3_init; int mode; - __u8 retbyte; static const struct usb_action *init_tb[SENSOR_MAX][2] = { {cs2102_InitialScale, cs2102_Initial}, /* 0 */ {cs2102K_InitialScale, cs2102K_Initial}, /* 1 */ @@ -7198,7 +7225,7 @@ static void sd_start(struct gspca_dev *gspca_dev) zcxx_probeSensor(gspca_dev); break; case SENSOR_PAS106: - usb_exchange(dev, pas106b_Initial_com); + usb_exchange(gspca_dev, pas106b_Initial_com); break; case SENSOR_PB0330: if (mode) { @@ -7214,14 +7241,15 @@ static void sd_start(struct gspca_dev *gspca_dev) } break; } - usb_exchange(dev, zc3_init); + usb_exchange(gspca_dev, zc3_init); switch (sd->sensor) { case SENSOR_GC0305: case SENSOR_OV7620: case SENSOR_PO2030: + case SENSOR_TAS5130C_VF0250: msleep(100); /* ?? */ - reg_r(dev, 0x0002, &retbyte); /* --> 0x40 */ + reg_r(gspca_dev, 0x0002); /* --> 0x40 */ reg_w(dev, 0x09, 0x01ad); /* (from win traces) */ reg_w(dev, 0x15, 0x01ae); reg_w(dev, 0x0d, 0x003a); @@ -7234,11 +7262,11 @@ static void sd_start(struct gspca_dev *gspca_dev) setbrightness(gspca_dev); switch (sd->sensor) { case SENSOR_OV7620: - reg_r(dev, 0x0008, &retbyte); + reg_r(gspca_dev, 0x0008); reg_w(dev, 0x00, 0x0008); break; case SENSOR_GC0305: - reg_r(dev, 0x0008, &retbyte); + reg_r(gspca_dev, 0x0008); /* fall thru */ case SENSOR_PO2030: reg_w(dev, 0x03, 0x0008); @@ -7263,7 +7291,7 @@ static void sd_start(struct gspca_dev *gspca_dev) setmatrix(gspca_dev); /* one more time? */ switch (sd->sensor) { case SENSOR_OV7620: - reg_r(dev, 0x0180, &retbyte); /* from win */ + reg_r(gspca_dev, 0x0180); /* from win */ reg_w(dev, 0x00, 0x0180); break; default: @@ -7281,7 +7309,7 @@ static void sd_start(struct gspca_dev *gspca_dev) break; case SENSOR_PO2030: reg_w(dev, 0x40, 0x0117); /* (from win traces) */ - reg_r(dev, 0x0180, &retbyte); + reg_r(gspca_dev, 0x0180); break; } @@ -7293,22 +7321,23 @@ static void sd_start(struct gspca_dev *gspca_dev) reg_w(dev, 0x15, 0x01ae); reg_w(dev, 0x40, 0x0180); reg_w(dev, 0x40, 0x0117); - reg_r(dev, 0x0180, &retbyte); + reg_r(gspca_dev, 0x0180); sd->autogain = 1; setautogain(gspca_dev); break; case SENSOR_OV7620: - i2c_read(dev, 0x13); /*fixme: returns 0xa3 */ - i2c_write(dev, 0x13, 0xa3, 0x00); /*fixme: same to send? */ + i2c_read(gspca_dev, 0x13); /*fixme: returns 0xa3 */ + i2c_write(gspca_dev, 0x13, 0xa3, 0x00); + /*fixme: returned value to send? */ reg_w(dev, 0x40, 0x0117); /* (from win traces) */ - reg_r(dev, 0x0180, &retbyte); + reg_r(gspca_dev, 0x0180); setautogain(gspca_dev); msleep(500); break; case SENSOR_PO2030: msleep(500); - reg_r(dev, 0x0008, &retbyte); - reg_r(dev, 0x0007, &retbyte); + reg_r(gspca_dev, 0x0008); + reg_r(gspca_dev, 0x0007); reg_w(dev, 0x00, 0x0007); /* (from win traces) */ reg_w(dev, 0x02, 0x0008); break; @@ -7331,9 +7360,8 @@ static void sd_close(struct gspca_dev *gspca_dev) { #if 0 /* test */ struct usb_device *dev = gspca_dev->dev; - __u8 buffread; - reg_r(dev, 0x0180, &buffread); + reg_r(gspca_dev, 0x0180); reg_w(dev, 0x00, 0x0180); reg_w(dev, 0x01, 0x0000); #endif @@ -7597,7 +7625,7 @@ static int __init sd_mod_init(void) { if (usb_register(&sd_driver) < 0) return -1; - PDEBUG(D_PROBE, "v%s registered", version); + PDEBUG(D_PROBE, "registered"); return 0; } |