Web lists-archives.com

[Spca50x-devs] [PATCH] sn9c120, OV7648... etc




thomas schorpp wrote:
got it today from ebay seller chellow:

it seems to be a
tom1:~# lsusb
Bus 004 Device 001: ID 0000:0000
Bus 003 Device 004: ID 0c45:613a Microdia <---------

who reported that? wrong company. default to chip manufacturer sonix for mass-oem.

-trying to get more information from windows driver *inf

Provider = %SX%
CatalogFile.NT = snpstd3.cat
DriverVer =  06/27/2006,5.16.0.000

%USBPCamV2Desc% =  SN.PCamV2.XP,USB\VID_0c45&PID_613a		; SN9C120 + OV7648	<-----

-trying to change/add pci product id forcing PCcam + or 168 driver

not do manage on first try, gspca2. dozens of storage class and undeclares,
startin patch attach, pls correct/conribute.

schorpp@tom1:/usr/src/gspca-20060813-b/gspcav2$ make
make -C /lib/modules/`uname -r`/build SUBDIRS=/usr/src/gspca-20060813-b/gspcav2 CC=cc modules
make[1]: Entering directory `/usr/src/linux-2.6.17.7'
 CC [M]  /usr/src/gspca-20060813-b/gspcav2/gspcaV2.o
In file included from /usr/src/gspca-20060813-b/gspcav2/Sonix/sonix.h:25,
                from /usr/src/gspca-20060813-b/gspcav2/gspcaV2.c:71:
/usr/src/gspca-20060813-b/gspcav2/Sonix/sn9cxxx.h:38: warning: 'struct spca50x_frame' declared inside parameter list
/usr/src/gspca-20060813-b/gspcav2/Sonix/sn9cxxx.h:38: warning: its scope is only this definition or declaration, which is probably not what you want
/usr/src/gspca-20060813-b/gspcav2/Sonix/sn9cxxx.h:61: error: 'sonix_config' undeclared here (not in a function)
/usr/src/gspca-20060813-b/gspcav2/Sonix/sn9cxxx.h:66: error: unknown field 'get_bright' specified in initializ
...
/usr/src/gspca-20060813-b/gspcav2/gspcaV2.c:2682: error: invalid storage class for function 'usb_gspca_init'
/usr/src/gspca-20060813-b/gspcav2/gspcaV2.c:2690: error: invalid storage class for function 'usb_gspca_exit'
/usr/src/gspca-20060813-b/gspcav2/gspcaV2.c:2695: error: invalid storage class for function '__inittest'
/usr/src/gspca-20060813-b/gspcav2/gspcaV2.c:2695: warning: 'alias' attribute ignored
/usr/src/gspca-20060813-b/gspcav2/gspcaV2.c:2696: error: invalid storage class for function '__exittest'
/usr/src/gspca-20060813-b/gspcav2/gspcaV2.c:2696: warning: ISO C90 forbids mixed declarations and code
/usr/src/gspca-20060813-b/gspcav2/gspcaV2.c:2696: warning: 'alias' attribute ignored
/usr/src/gspca-20060813-b/gspcav2/gspcaV2.c:2696: error: expected declaration or statement at end of input
make[2]: *** [/usr/src/gspca-20060813-b/gspcav2/gspcaV2.o] Error 1
make[1]: *** [_module_/usr/src/gspca-20060813-b/gspcav2] Error 2
make[1]: Leaving directory `/usr/src/linux-2.6.17.7'
make: *** [default] Error 2
schorpp@tom1:/usr/src/gspca-20060813-b/gspcav2$
dont know the dependencies yet...

tom
diff -U 3 -H -d -r -N -- gspca-20060813-a/gspcav2/Sonix/sonix.h gspca-20060813-b/gspcav2/Sonix/sonix.h
--- gspca-20060813-a/gspcav2/Sonix/sonix.h	2006-08-05 15:14:02.000000000 +0200
+++ gspca-20060813-b/gspcav2/Sonix/sonix.h	2006-09-16 20:44:00.000000000 +0200
@@ -22,6 +22,8 @@
 #                                                                           #
 ****************************************************************************/
 
+#include "sn9cxxx.h"
+
 #define COMP2 0x8F
 #define COMP 0xC7		//0x87 //0x07
 #define COMP1 0xC9		//0x89 //0x09
@@ -86,7 +88,6 @@
 }
 
 /*****************************************************************/
-#include "sn9cxxx.h"
 static struct cam_operation fsonix = {
 	.initialize = sonix_init,
 	.configure = sonix_config,
@@ -951,6 +952,13 @@
 			camera->i2c_ctrl_reg = 0x81;
 			camera->i2c_base = 0x11;
 			break;
+			case 0x613a:
+			gspca_dev->desc = SonixPlus;
+			gspca_dev->sensor = SENSOR_OV7630;	// compatible ?
+			camera->customid = SN9C120;
+			camera->i2c_ctrl_reg = 0x80;	// i2c adresses ok ?
+			camera->i2c_base = 0x21;
+			break;
 		break;	
 	}
 switch (camera->customid){
diff -U 3 -H -d -r -N -- gspca-20060813-a/gspcav2/gspcaV2.c gspca-20060813-b/gspcav2/gspcaV2.c
--- gspca-20060813-a/gspcav2/gspcaV2.c	2006-06-18 14:35:00.000000000 +0200
+++ gspca-20060813-b/gspcav2/gspcaV2.c	2006-09-16 19:37:00.000000000 +0200
@@ -68,11 +68,13 @@
 
 static const char version[] = GSPCA_VERSION;
 #include "gspcaV2.h"
-#define VIMICRO 1
+#include "Sonix/sonix.h"
+
+#define SONIX 1 // sch
 #define DRIVER_VERSION_NUMBER	KERNEL_VERSION(1, 0, 0)
 
 static int video_nr = -1;
-static int debug = 0;
+static int debug = 2;
 module_param(debug, int, 0644);
 MODULE_PARM_DESC(debug,
 		 "Debug level: 0=warning, 1=memory, 2=init/config,"
@@ -289,6 +291,7 @@
 	LogitechQCCool,
 	QCimconnect,
 	QCmessenger,
+	SonixPlus,
 	LastCamera
 };
 static struct cam_list clist[] = {
@@ -457,6 +460,7 @@
 	{LogitechQCCool, "Logitech QuickCam Cool"},
 	{QCimconnect, "Logitech QuickCam IM/Connect "},
 	{QCmessenger, "Logitech QuickCam Messenger "},
+	{SonixPlus, "Sonix Pccam Plus sn9c120 OV7648 "},	//sch
 	{-1, NULL}
 };
 static __devinitdata struct usb_device_id device_table[] = {
@@ -628,6 +632,7 @@
 	{USB_DEVICE(0x046d, 0x08d9)},	/* Logitech QuickCam IM/Connect */
 	{USB_DEVICE(0x046d, 0x08da)},	/* Logitech QuickCam Messenger */
 	{USB_DEVICE(0x0000, 0x0000)},	/* MystFromOri Unknow Camera */
+	{USB_DEVICE(0x0c45, 0x613a)},	/* Sonix Pccam Plus sn9c120 OV7648 sch*/
 	{}			/* Terminating entry */
 };
 
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Spca50x-devs mailing list
Spca50x-devs@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/spca50x-devs