Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
sn9c20x.c File Reference
#include <linux/input.h>
#include "gspca.h"
#include "jpeg.h"
#include <media/v4l2-chip-ident.h>
#include <linux/dmi.h>

Go to the source code of this file.

Data Structures

struct  sd
 
struct  i2c_reg_u8
 
struct  i2c_reg_u16
 

Macros

#define pr_fmt(fmt)   KBUILD_MODNAME ": " fmt
 
#define SCALE_MASK   0x0f
 
#define SCALE_160x120   0
 
#define SCALE_320x240   1
 
#define SCALE_640x480   2
 
#define SCALE_1280x1024   3
 
#define MODE_RAW   0x10
 
#define MODE_JPEG   0x20
 
#define MODE_SXGA   0x80
 
#define SENSOR_OV9650   0
 
#define SENSOR_OV9655   1
 
#define SENSOR_SOI968   2
 
#define SENSOR_OV7660   3
 
#define SENSOR_OV7670   4
 
#define SENSOR_MT9V011   5
 
#define SENSOR_MT9V111   6
 
#define SENSOR_MT9V112   7
 
#define SENSOR_MT9M001   8
 
#define SENSOR_MT9M111   9
 
#define SENSOR_MT9M112   10
 
#define SENSOR_HV7131R   11
 
#define SENSOR_MT9VPRB   12
 
#define HAS_NO_BUTTON   0x1
 
#define LED_REVERSE   0x2 /* some cameras unset gpio to turn on leds */
 
#define FLIP_DETECT   0x4
 
#define MIN_AVG_LUM   80
 
#define MAX_AVG_LUM   130
 
#define HW_WIN(mode, hstart, vstart)
 
#define CLR_WIN(width, height)
 
#define SN9C20X(sensor, i2c_addr, flags)
 

Functions

 MODULE_AUTHOR ("Brian Johnson <[email protected]>, ""microdia project <[email protected]>")
 
 MODULE_DESCRIPTION ("GSPCA/SN9C20X USB Camera Driver")
 
 MODULE_LICENSE ("GPL")
 
 MODULE_DEVICE_TABLE (usb, device_table)
 
 module_usb_driver (sd_driver)
 

Macro Definition Documentation

#define CLR_WIN (   width,
  height 
)
Value:
((const u8 [])\
{0, width >> 2, 0, height >> 1,\
((width >> 10) & 0x01) | ((height >> 8) & 0x6)})

Definition at line 2014 of file sn9c20x.c.

#define FLIP_DETECT   0x4

Definition at line 67 of file sn9c20x.c.

#define HAS_NO_BUTTON   0x1

Definition at line 65 of file sn9c20x.c.

#define HW_WIN (   mode,
  hstart,
  vstart 
)
Value:
((const u8 []){hstart, 0, vstart, 0, \
(mode & MODE_SXGA ? 1280 >> 4 : 640 >> 4), \
(mode & MODE_SXGA ? 1024 >> 3 : 480 >> 3)})

Definition at line 2009 of file sn9c20x.c.

#define LED_REVERSE   0x2 /* some cameras unset gpio to turn on leds */

Definition at line 66 of file sn9c20x.c.

#define MAX_AVG_LUM   130

Definition at line 104 of file sn9c20x.c.

#define MIN_AVG_LUM   80

Definition at line 103 of file sn9c20x.c.

#define MODE_JPEG   0x20

Definition at line 47 of file sn9c20x.c.

#define MODE_RAW   0x10

Definition at line 46 of file sn9c20x.c.

#define MODE_SXGA   0x80

Definition at line 48 of file sn9c20x.c.

#define pr_fmt (   fmt)    KBUILD_MODNAME ": " fmt

Definition at line 23 of file sn9c20x.c.

#define SCALE_1280x1024   3

Definition at line 45 of file sn9c20x.c.

#define SCALE_160x120   0

Definition at line 42 of file sn9c20x.c.

#define SCALE_320x240   1

Definition at line 43 of file sn9c20x.c.

#define SCALE_640x480   2

Definition at line 44 of file sn9c20x.c.

#define SCALE_MASK   0x0f

Definition at line 41 of file sn9c20x.c.

#define SENSOR_HV7131R   11

Definition at line 61 of file sn9c20x.c.

#define SENSOR_MT9M001   8

Definition at line 58 of file sn9c20x.c.

#define SENSOR_MT9M111   9

Definition at line 59 of file sn9c20x.c.

#define SENSOR_MT9M112   10

Definition at line 60 of file sn9c20x.c.

#define SENSOR_MT9V011   5

Definition at line 55 of file sn9c20x.c.

#define SENSOR_MT9V111   6

Definition at line 56 of file sn9c20x.c.

#define SENSOR_MT9V112   7

Definition at line 57 of file sn9c20x.c.

#define SENSOR_MT9VPRB   12

Definition at line 62 of file sn9c20x.c.

#define SENSOR_OV7660   3

Definition at line 53 of file sn9c20x.c.

#define SENSOR_OV7670   4

Definition at line 54 of file sn9c20x.c.

#define SENSOR_OV9650   0

Definition at line 50 of file sn9c20x.c.

#define SENSOR_OV9655   1

Definition at line 51 of file sn9c20x.c.

#define SENSOR_SOI968   2

Definition at line 52 of file sn9c20x.c.

#define SN9C20X (   sensor,
  i2c_addr,
  flags 
)
Value:
.driver_info = ((flags & 0xff) << 16) \
| (SENSOR_ ## sensor << 8) \

Definition at line 2363 of file sn9c20x.c.

Function Documentation

MODULE_AUTHOR ( "Brian Johnson <[email protected] ,
""microdia project< microdia @googlegroups.com >"   
)
MODULE_DESCRIPTION ( "GSPCA/SN9C20X USB Camera Driver"  )
MODULE_DEVICE_TABLE ( usb  ,
device_table   
)
MODULE_LICENSE ( "GPL"  )
module_usb_driver ( sd_driver  )