aboutsummaryrefslogtreecommitdiff
path: root/drivers/media
diff options
context:
space:
mode:
authorErik Andrén <erik.andren@gmail.com>2009-06-21 14:58:55 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-09-19 00:17:40 -0300
commitbf40b382f6ce53cdee48917d14b13ae004c3deab (patch)
tree4440afd19eb490c47688405af2502333f98f8c98 /drivers/media
parent7c7ddf1638a45923ab053d1f7818c6d123148b4b (diff)
V4L/DVB (12984): gspca - m5602-ov7660: Use a new raw init
Signed-off-by: Erik Andrén <erik.andren@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/video/gspca/m5602/m5602_ov7660.c12
-rw-r--r--drivers/media/video/gspca/m5602/m5602_ov7660.h248
2 files changed, 254 insertions, 6 deletions
diff --git a/drivers/media/video/gspca/m5602/m5602_ov7660.c b/drivers/media/video/gspca/m5602/m5602_ov7660.c
index 80c64caac35..f7c050f2552 100644
--- a/drivers/media/video/gspca/m5602/m5602_ov7660.c
+++ b/drivers/media/video/gspca/m5602/m5602_ov7660.c
@@ -211,17 +211,17 @@ int ov7660_init(struct sd *sd)
s32 *sensor_settings = sd->sensor_priv;
/* Init the sensor */
- for (i = 0; i < ARRAY_SIZE(init_ov7660); i++) {
+ for (i = 0; i < ARRAY_SIZE(init2_ov7660); i++) {
u8 data[2];
- if (init_ov7660[i][0] == BRIDGE) {
+ if (init2_ov7660[i][0] == BRIDGE) {
err = m5602_write_bridge(sd,
- init_ov7660[i][1],
- init_ov7660[i][2]);
+ init2_ov7660[i][1],
+ init2_ov7660[i][2]);
} else {
- data[0] = init_ov7660[i][2];
+ data[0] = init2_ov7660[i][2];
err = m5602_write_sensor(sd,
- init_ov7660[i][1], data, 1);
+ init2_ov7660[i][1], data, 1);
}
}
diff --git a/drivers/media/video/gspca/m5602/m5602_ov7660.h b/drivers/media/video/gspca/m5602/m5602_ov7660.h
index 8027b64b7d5..eb0b50ed00e 100644
--- a/drivers/media/video/gspca/m5602/m5602_ov7660.h
+++ b/drivers/media/video/gspca/m5602/m5602_ov7660.h
@@ -270,4 +270,252 @@ static const unsigned char init_ov7660[][4] =
{BRIDGE, M5602_XB_SEN_CLK_CTRL, 0xb0}
};
+static const unsigned char init2_ov7660[][4] = {
+ {BRIDGE, 0x13, 0x02},
+ {BRIDGE, 0x12, 0xb0},
+ {BRIDGE, 0x15, 0x00},
+ {BRIDGE, 0x14, 0xb0},
+ {BRIDGE, 0x60, 0xc0},
+ {BRIDGE, 0x00, 0x0d},
+ {BRIDGE, 0x01, 0x00},
+ {BRIDGE, 0x77, 0x01},
+ {BRIDGE, 0x77, 0x01},
+ {BRIDGE, 0x15, 0x00},
+ {BRIDGE, 0x14, 0xb0},
+ {BRIDGE, 0x60, 0xc0},
+ {BRIDGE, 0x00, 0x0c},
+ {BRIDGE, 0x77, 0x05},
+ {BRIDGE, 0x76, 0x00},
+ {BRIDGE, 0x74, 0x06},
+ {BRIDGE, 0x75, 0x00},
+ {SENSOR, 0x12, 0x80},
+ {SENSOR, 0x11, 0x80},
+ {SENSOR, 0x01, 0x80},
+ {SENSOR, 0x02, 0x80},
+ {SENSOR, 0x14, 0x4c},
+ {SENSOR, 0x39, 0x43},
+ {SENSOR, 0x3c, 0x28},
+ {SENSOR, 0x13, 0x00},
+ {SENSOR, 0x15, 0x40},
+ {SENSOR, 0x17, 0x0c},
+ {SENSOR, 0x18, 0x61},
+ {SENSOR, 0x32, 0xa4},
+ {SENSOR, 0x1b, 0x0b},
+ {SENSOR, 0x19, 0x01},
+ {SENSOR, 0x1a, 0x7a},
+ {SENSOR, 0x03, 0x00},
+ {SENSOR, 0x12, 0x05},
+ {SENSOR, 0x0f, 0x42},
+ {SENSOR, 0x27, 0x94},
+ {SENSOR, 0x28, 0x94},
+ {SENSOR, 0x29, 0x94},
+ {SENSOR, 0x2c, 0x94},
+ {SENSOR, 0x04, 0x00},
+ {SENSOR, 0x10, 0x00},
+ {SENSOR, 0x07, 0x00},
+ {SENSOR, 0x37, 0x05},
+ {SENSOR, 0x3d, 0x00},
+ {SENSOR, 0xa1, 0x23},
+ {SENSOR, 0x3a, 0x0d},
+ {SENSOR, 0x69, 0x80},
+ {SENSOR, 0x62, 0x00},
+ {SENSOR, 0x63, 0x00},
+ {SENSOR, 0x64, 0x10},
+ {SENSOR, 0x65, 0x40},
+ {SENSOR, 0x66, 0x01},
+ {BRIDGE, 0x15, 0x06},
+ {BRIDGE, 0x14, 0xb0},
+ {BRIDGE, 0x60, 0xc0},
+ {BRIDGE, 0x00, 0x0c},
+ {BRIDGE, 0x02, 0x81},
+ {BRIDGE, 0x04, 0x82},
+ {BRIDGE, 0x0a, 0x01},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x06, 0x08},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x06, 0x01},
+ {BRIDGE, 0x06, 0xec},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x0a, 0x00},
+ {BRIDGE, 0x0a, 0x02},
+ {BRIDGE, 0x07, 0x00},
+ {BRIDGE, 0x07, 0x27},
+ {BRIDGE, 0x07, 0x02},
+ {BRIDGE, 0x07, 0xae},
+ {BRIDGE, 0x0a, 0x00},
+ {SENSOR, 0x01, 0x80},
+ {SENSOR, 0x02, 0x80},
+ {BRIDGE, 0x15, 0x02},
+ {BRIDGE, 0x14, 0xb0},
+ {SENSOR, 0x10, 0x20},
+ {SENSOR, 0x04, 0x00},
+ {SENSOR, 0x00, 0x07},
+ {SENSOR, 0x39, 0x0c},
+ {SENSOR, 0x09, 0x11},
+ {SENSOR, 0x12, 0x05},
+ {BRIDGE, 0x77, 0x01},
+ {BRIDGE, 0x76, 0x04},
+ {BRIDGE, 0x74, 0x06},
+ {BRIDGE, 0x72, 0x06},
+ {BRIDGE, 0x70, 0x00},
+ {BRIDGE, 0x15, 0x08},
+ {BRIDGE, 0x14, 0xb0},
+ {BRIDGE, 0x15, 0x00},
+ {BRIDGE, 0x14, 0xb0},
+ {BRIDGE, 0x60, 0xc0},
+ {BRIDGE, 0x00, 0x0c},
+ {BRIDGE, 0x77, 0x05},
+ {BRIDGE, 0x76, 0x00},
+ {BRIDGE, 0x74, 0x06},
+ {BRIDGE, 0x75, 0x00},
+ {SENSOR, 0x12, 0x80},
+ {SENSOR, 0x11, 0x80},
+ {SENSOR, 0x01, 0x80},
+ {SENSOR, 0x02, 0x80},
+ {SENSOR, 0x14, 0x4c},
+ {SENSOR, 0x39, 0x43},
+ {SENSOR, 0x3c, 0x28},
+ {SENSOR, 0x13, 0x00},
+ {SENSOR, 0x15, 0x40},
+ {SENSOR, 0x17, 0x0c},
+ {SENSOR, 0x18, 0x61},
+ {SENSOR, 0x32, 0xa4},
+ {SENSOR, 0x1b, 0x0b},
+ {SENSOR, 0x19, 0x01},
+ {SENSOR, 0x1a, 0x7a},
+ {SENSOR, 0x03, 0x00},
+ {SENSOR, 0x12, 0x05},
+ {SENSOR, 0x0f, 0x42},
+ {SENSOR, 0x27, 0x94},
+ {SENSOR, 0x28, 0x94},
+ {SENSOR, 0x29, 0x94},
+ {SENSOR, 0x2c, 0x94},
+ {SENSOR, 0x04, 0x00},
+ {SENSOR, 0x10, 0x00},
+ {SENSOR, 0x07, 0x00},
+ {SENSOR, 0x37, 0x05},
+ {SENSOR, 0x3d, 0x00},
+ {SENSOR, 0xa1, 0x23},
+ {SENSOR, 0x3a, 0x0d},
+ {SENSOR, 0x69, 0x80},
+ {SENSOR, 0x62, 0x00},
+ {SENSOR, 0x63, 0x00},
+ {SENSOR, 0x64, 0x10},
+ {SENSOR, 0x65, 0x40},
+ {SENSOR, 0x66, 0x01},
+ {BRIDGE, 0x15, 0x06},
+ {BRIDGE, 0x14, 0xb0},
+ {BRIDGE, 0x60, 0xc0},
+ {BRIDGE, 0x00, 0x0c},
+ {BRIDGE, 0x02, 0x81},
+ {BRIDGE, 0x04, 0x82},
+ {BRIDGE, 0x0a, 0x01},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x06, 0x08},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x06, 0x01},
+ {BRIDGE, 0x06, 0xec},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x0a, 0x00},
+ {BRIDGE, 0x0a, 0x02},
+ {BRIDGE, 0x07, 0x00},
+ {BRIDGE, 0x07, 0x27},
+ {BRIDGE, 0x07, 0x02},
+ {BRIDGE, 0x07, 0xae},
+ {BRIDGE, 0x0a, 0x00},
+ {SENSOR, 0x01, 0x80},
+ {SENSOR, 0x02, 0x80},
+ {BRIDGE, 0x15, 0x00},
+ {BRIDGE, 0x14, 0xb0},
+ {SENSOR, 0x10, 0x5f},
+ {SENSOR, 0x04, 0x03},
+ {SENSOR, 0x00, 0x02},
+ {SENSOR, 0x39, 0x0c},
+ {SENSOR, 0x09, 0x11},
+ {SENSOR, 0x12, 0x05},
+ {BRIDGE, 0x77, 0x01},
+ {BRIDGE, 0x76, 0x04},
+ {BRIDGE, 0x74, 0x06},
+ {BRIDGE, 0x72, 0x06},
+ {BRIDGE, 0x70, 0x00},
+ {BRIDGE, 0x15, 0x08},
+ {BRIDGE, 0x14, 0xb0},
+ {BRIDGE, 0x15, 0x00},
+ {BRIDGE, 0x14, 0xb0},
+ {BRIDGE, 0x60, 0xc0},
+ {BRIDGE, 0x00, 0x0c},
+ {BRIDGE, 0x77, 0x05},
+ {BRIDGE, 0x76, 0x00},
+ {BRIDGE, 0x74, 0x06},
+ {BRIDGE, 0x75, 0x00},
+ {SENSOR, 0x12, 0x80},
+ {SENSOR, 0x11, 0x80},
+ {SENSOR, 0x01, 0x80},
+ {SENSOR, 0x02, 0x80},
+ {SENSOR, 0x14, 0x4c},
+ {SENSOR, 0x39, 0x43},
+ {SENSOR, 0x3c, 0x28},
+ {SENSOR, 0x13, 0x00},
+ {SENSOR, 0x15, 0x40},
+ {SENSOR, 0x17, 0x0c},
+ {SENSOR, 0x18, 0x61},
+ {SENSOR, 0x32, 0xa4},
+ {SENSOR, 0x1b, 0x0b},
+ {SENSOR, 0x19, 0x01},
+ {SENSOR, 0x1a, 0x7a},
+ {SENSOR, 0x03, 0x00},
+ {SENSOR, 0x12, 0x05},
+ {SENSOR, 0x0f, 0x42},
+ {SENSOR, 0x27, 0x94},
+ {SENSOR, 0x28, 0x94},
+ {SENSOR, 0x29, 0x94},
+ {SENSOR, 0x2c, 0x94},
+ {SENSOR, 0x04, 0x00},
+ {SENSOR, 0x10, 0x00},
+ {SENSOR, 0x07, 0x00},
+ {SENSOR, 0x37, 0x05},
+ {SENSOR, 0x3d, 0x00},
+ {SENSOR, 0xa1, 0x23},
+ {SENSOR, 0x3a, 0x0d},
+ {SENSOR, 0x69, 0x80},
+ {SENSOR, 0x62, 0x00},
+ {SENSOR, 0x63, 0x00},
+ {SENSOR, 0x64, 0x10},
+ {SENSOR, 0x65, 0x40},
+ {SENSOR, 0x66, 0x01},
+ {BRIDGE, 0x15, 0x06},
+ {BRIDGE, 0x14, 0xb0},
+ {BRIDGE, 0x60, 0xc0},
+ {BRIDGE, 0x00, 0x0c},
+ {BRIDGE, 0x02, 0x81},
+ {BRIDGE, 0x04, 0x82},
+ {BRIDGE, 0x0a, 0x01},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x06, 0x08},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x06, 0x01},
+ {BRIDGE, 0x06, 0xec},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x06, 0x00},
+ {BRIDGE, 0x0a, 0x00},
+ {BRIDGE, 0x0a, 0x02},
+ {BRIDGE, 0x07, 0x00},
+ {BRIDGE, 0x07, 0x27},
+ {BRIDGE, 0x07, 0x02},
+ {BRIDGE, 0x07, 0xae},
+ {BRIDGE, 0x0a, 0x00},
+ {SENSOR, 0x01, 0x80},
+ {SENSOR, 0x02, 0x80},
+ {BRIDGE, 0x15, 0x00},
+ {BRIDGE, 0x14, 0xb0},
+ {SENSOR, 0x10, 0x5f},
+ {SENSOR, 0x04, 0x03},
+ {SENSOR, 0x00, 0x02}
+};
+
#endif