Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 164187
b: refs/heads/master
c: eb3678f
h: refs/heads/master
i:
  164185: 9488e18
  164183: 92d0713
v: v3
  • Loading branch information
Erik Andrén authored and Mauro Carvalho Chehab committed Sep 19, 2009
1 parent c9db9f4 commit a4a2dcd
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 136 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 2ec92c28d73a0d2206c961180b955876d4f62a94
refs/heads/master: eb3678fbe5d5be8315628885b7c93228c97a433d
12 changes: 6 additions & 6 deletions trunk/drivers/media/video/gspca/m5602/m5602_ov7660.c
Original file line number Diff line number Diff line change
Expand Up @@ -244,17 +244,17 @@ int ov7660_init(struct sd *sd)
s32 *sensor_settings = sd->sensor_priv;

/* Init the sensor */
for (i = 0; i < ARRAY_SIZE(init2_ov7660); i++) {
for (i = 0; i < ARRAY_SIZE(init_ov7660); i++) {
u8 data[2];

if (init2_ov7660[i][0] == BRIDGE) {
if (init_ov7660[i][0] == BRIDGE) {
err = m5602_write_bridge(sd,
init2_ov7660[i][1],
init2_ov7660[i][2]);
init_ov7660[i][1],
init_ov7660[i][2]);
} else {
data[0] = init2_ov7660[i][2];
data[0] = init_ov7660[i][2];
err = m5602_write_sensor(sd,
init2_ov7660[i][1], data, 1);
init_ov7660[i][1], data, 1);
}
}

Expand Down
129 changes: 0 additions & 129 deletions trunk/drivers/media/video/gspca/m5602/m5602_ov7660.h
Original file line number Diff line number Diff line change
Expand Up @@ -142,135 +142,6 @@ static const unsigned char preinit_ov7660[][4] =

static const unsigned char init_ov7660[][4] =
{
{BRIDGE, M5602_XB_MCU_CLK_DIV, 0x02},
{BRIDGE, M5602_XB_MCU_CLK_CTRL, 0xb0},
{BRIDGE, M5602_XB_SEN_CLK_DIV, 0x00},
{BRIDGE, M5602_XB_SEN_CLK_CTRL, 0xb0},
{BRIDGE, M5602_XB_ADC_CTRL, 0xc0},
{BRIDGE, M5602_XB_SENSOR_TYPE, 0x0d},
{BRIDGE, M5602_XB_SENSOR_CTRL, 0x00},
{BRIDGE, M5602_XB_GPIO_DIR, 0x03},
{BRIDGE, M5602_XB_GPIO_DIR, 0x03},
{BRIDGE, M5602_XB_ADC_CTRL, 0xc0},
{BRIDGE, M5602_XB_SENSOR_TYPE, 0x0c},

{SENSOR, OV7660_OFON, 0x0c},
{SENSOR, OV7660_COM2, 0x11},
{SENSOR, OV7660_COM7, 0x05},

{BRIDGE, M5602_XB_GPIO_DIR, 0x01},
{BRIDGE, M5602_XB_GPIO_DAT, 0x04},
{BRIDGE, M5602_XB_GPIO_EN_H, 0x06},
{BRIDGE, M5602_XB_GPIO_DIR_H, 0x06},
{BRIDGE, M5602_XB_GPIO_DAT_H, 0x00},
{BRIDGE, M5602_XB_SEN_CLK_DIV, 0x08},
{BRIDGE, M5602_XB_SEN_CLK_CTRL, 0xb0},
{BRIDGE, M5602_XB_SEN_CLK_DIV, 0x00},
{BRIDGE, M5602_XB_SEN_CLK_CTRL, 0xb0},
{BRIDGE, M5602_XB_ADC_CTRL, 0xc0},
{BRIDGE, M5602_XB_SENSOR_TYPE, 0x0c},
{BRIDGE, M5602_XB_GPIO_DIR, 0x05},
{BRIDGE, M5602_XB_GPIO_DAT, 0x00},
{BRIDGE, M5602_XB_GPIO_EN_H, 0x06},
{BRIDGE, M5602_XB_GPIO_EN_L, 0x00},

{BRIDGE, M5602_XB_SEN_CLK_DIV, 0x02},
{BRIDGE, M5602_XB_SEN_CLK_CTRL, 0xb0},

{SENSOR, OV7660_AECH, OV7660_DEFAULT_EXPOSURE},
{SENSOR, OV7660_COM1, 0x00},

{BRIDGE, M5602_XB_GPIO_DIR, 0x01},
{BRIDGE, M5602_XB_GPIO_DAT, 0x04},
{BRIDGE, M5602_XB_GPIO_EN_H, 0x06},
{BRIDGE, M5602_XB_GPIO_DIR_H, 0x06},
{BRIDGE, M5602_XB_GPIO_DAT_H, 0x00},
{BRIDGE, M5602_XB_SEN_CLK_DIV, 0x08},
{BRIDGE, M5602_XB_SEN_CLK_CTRL, 0xb0},

{BRIDGE, M5602_XB_SEN_CLK_DIV, 0x00},
{BRIDGE, M5602_XB_SEN_CLK_CTRL, 0xb0},
{BRIDGE, M5602_XB_ADC_CTRL, 0xc0},
{BRIDGE, M5602_XB_SENSOR_TYPE, 0x0c},
{BRIDGE, M5602_XB_GPIO_DIR, 0x05},
{BRIDGE, M5602_XB_GPIO_DAT, 0x00},
{BRIDGE, M5602_XB_GPIO_EN_H, 0x06},
{BRIDGE, M5602_XB_GPIO_EN_L, 0x00},

{SENSOR, OV7660_COM7, 0x80},
{SENSOR, OV7660_CLKRC, 0x80},
{SENSOR, OV7660_COM9, 0x4c},
{SENSOR, OV7660_OFON, 0x43},
{SENSOR, OV7660_COM12, 0x28},
{SENSOR, OV7660_COM8, 0x00},
{SENSOR, OV7660_COM10, 0x40},
{SENSOR, OV7660_HSTART, 0x0c},
{SENSOR, OV7660_HSTOP, 0x61},
{SENSOR, OV7660_HREF, 0xa4},
{SENSOR, OV7660_PSHFT, 0x0b},
{SENSOR, OV7660_VSTART, 0x01},
{SENSOR, OV7660_VSTOP, 0x7a},
{SENSOR, OV7660_VREF, 0x00},
{SENSOR, OV7660_COM7, 0x05},
{SENSOR, OV7660_COM6, 0x4b},
{SENSOR, OV7660_BBIAS, 0x98},
{SENSOR, OV7660_GbBIAS, 0x98},
{SENSOR, OV7660_RSVD29, 0x98},
{SENSOR, OV7660_RBIAS, 0x98},
{SENSOR, OV7660_COM1, 0x00},
{SENSOR, OV7660_AECHH, 0x00},
{SENSOR, OV7660_ADC, 0x04},
{SENSOR, OV7660_COM13, 0x00},
{SENSOR, OV7660_RSVDA1, 0x23},
{SENSOR, OV7660_TSLB, 0x0d},
{SENSOR, OV7660_HV, 0x80},
{SENSOR, OV7660_LCC1, 0x00},
{SENSOR, OV7660_LCC2, 0x00},
{SENSOR, OV7660_LCC3, 0x10},
{SENSOR, OV7660_LCC4, 0x40},
{SENSOR, OV7660_LCC5, 0x01},

{BRIDGE, M5602_XB_SEN_CLK_DIV, 0x06},
{BRIDGE, M5602_XB_SEN_CLK_CTRL, 0xb0},
{BRIDGE, M5602_XB_ADC_CTRL, 0xc0},
{BRIDGE, M5602_XB_SENSOR_TYPE, 0x0c},
{BRIDGE, M5602_XB_LINE_OF_FRAME_H, 0x81},
{BRIDGE, M5602_XB_PIX_OF_LINE_H, 0x82},
{BRIDGE, M5602_XB_SIG_INI, 0x01},
{BRIDGE, M5602_XB_VSYNC_PARA, 0x00},
{BRIDGE, M5602_XB_VSYNC_PARA, 0x08},
{BRIDGE, M5602_XB_VSYNC_PARA, 0x00},
{BRIDGE, M5602_XB_VSYNC_PARA, 0x00},
{BRIDGE, M5602_XB_VSYNC_PARA, 0x01},
{BRIDGE, M5602_XB_VSYNC_PARA, 0xe0}, /* 480 */
{BRIDGE, M5602_XB_VSYNC_PARA, 0x00},
{BRIDGE, M5602_XB_VSYNC_PARA, 0x00},
{BRIDGE, M5602_XB_SIG_INI, 0x00},
{BRIDGE, M5602_XB_SIG_INI, 0x02},
{BRIDGE, M5602_XB_VSYNC_PARA, 0x00},
{BRIDGE, M5602_XB_VSYNC_PARA, 0x27}, /* 39 */
{BRIDGE, M5602_XB_VSYNC_PARA, 0x02},
{BRIDGE, M5602_XB_VSYNC_PARA, 0xa7}, /* 679 */
{BRIDGE, M5602_XB_SIG_INI, 0x00},

{BRIDGE, M5602_XB_SEN_CLK_DIV, 0x00},
{BRIDGE, M5602_XB_SEN_CLK_CTRL, 0xb0},

{SENSOR, OV7660_COM1, 0x00},
{SENSOR, OV7660_OFON, 0x0c},
{SENSOR, OV7660_COM2, 0x11}, /* Soft sleep, 2x Drive */
{SENSOR, OV7660_COM7, 0x05}, /* Raw RGB */

{BRIDGE, M5602_XB_GPIO_DIR, 0x01},
{BRIDGE, M5602_XB_GPIO_DAT, 0x04},
{BRIDGE, M5602_XB_GPIO_EN_H, 0x06},
{BRIDGE, M5602_XB_GPIO_DIR_H, 0x06},
{BRIDGE, M5602_XB_GPIO_DAT_H, 0x00},
{BRIDGE, M5602_XB_SEN_CLK_DIV, 0x08},
{BRIDGE, M5602_XB_SEN_CLK_CTRL, 0xb0}
};

static const unsigned char init2_ov7660[][4] = {
{BRIDGE, M5602_XB_MCU_CLK_DIV, 0x02},
{BRIDGE, M5602_XB_MCU_CLK_CTRL, 0xb0},
{BRIDGE, M5602_XB_SEN_CLK_DIV, 0x00},
Expand Down

0 comments on commit a4a2dcd

Please sign in to comment.