diff options
author | Erik Andr?n <erik.andren@gmail.com> | 2008-12-31 11:25:42 +0100 |
---|---|---|
committer | Erik Andr?n <erik.andren@gmail.com> | 2008-12-31 11:25:42 +0100 |
commit | bf2b33554b1eb89b8266720f9651a9d52240d1d3 (patch) | |
tree | 25f5e269dfdc3d8f137c0cdf212c9f81326fa2e7 /linux/drivers/media/video/gspca | |
parent | eed2ee4f687a72b34352aac05672296f90826b6b (diff) | |
download | mediapointer-dvb-s2-bf2b33554b1eb89b8266720f9651a9d52240d1d3.tar.gz mediapointer-dvb-s2-bf2b33554b1eb89b8266720f9651a9d52240d1d3.tar.bz2 |
gspca - m5602-ov9650: Don't read exposure data from COM1.
From: Erik Andr?n <erik.andren@gmail.com>
ov9650: Reading the COM1 register corrupts the image.
Decrease the granularity of the exposure and limit its upper range
as setting such high values doesn't have any effect on the image.
Priority: normal
Signed-off-by: Erik Andr?n <erik.andren@gmail.com>
Diffstat (limited to 'linux/drivers/media/video/gspca')
-rw-r--r-- | linux/drivers/media/video/gspca/m5602/m5602_ov9650.c | 9 | ||||
-rw-r--r-- | linux/drivers/media/video/gspca/m5602/m5602_ov9650.h | 2 |
2 files changed, 3 insertions, 8 deletions
diff --git a/linux/drivers/media/video/gspca/m5602/m5602_ov9650.c b/linux/drivers/media/video/gspca/m5602/m5602_ov9650.c index d7e4e080e..73a889630 100644 --- a/linux/drivers/media/video/gspca/m5602/m5602_ov9650.c +++ b/linux/drivers/media/video/gspca/m5602/m5602_ov9650.c @@ -77,8 +77,8 @@ const static struct ctrl ov9650_ctrls[] = { .type = V4L2_CTRL_TYPE_INTEGER, .name = "exposure", .minimum = 0x00, - .maximum = 0xffff, - .step = 0x1, + .maximum = 0x1ff, + .step = 0x4, .default_value = EXPOSURE_DEFAULT, .flags = V4L2_CTRL_FLAG_SLIDER }, @@ -409,11 +409,6 @@ int ov9650_get_exposure(struct gspca_dev *gspca_dev, __s32 *val) u8 i2c_data; int err; - err = m5602_read_sensor(sd, OV9650_COM1, &i2c_data, 1); - if (err < 0) - return err; - *val = i2c_data & 0x03; - err = m5602_read_sensor(sd, OV9650_AECH, &i2c_data, 1); if (err < 0) return err; diff --git a/linux/drivers/media/video/gspca/m5602/m5602_ov9650.h b/linux/drivers/media/video/gspca/m5602/m5602_ov9650.h index 08ae7ea96..ca0e42ee0 100644 --- a/linux/drivers/media/video/gspca/m5602/m5602_ov9650.h +++ b/linux/drivers/media/video/gspca/m5602/m5602_ov9650.h @@ -123,7 +123,7 @@ #define GAIN_DEFAULT 0x14 #define RED_GAIN_DEFAULT 0x70 #define BLUE_GAIN_DEFAULT 0x20 -#define EXPOSURE_DEFAULT 0x5003 +#define EXPOSURE_DEFAULT 0x1ff /*****************************************************************************/ |