All the afraid thoughts of the projects deadness are quite far from the truth. We'll keep working until we get this thing running and we're not that far away from our goal, at least on the very basic level using the resolution 640x480. Right now our biggest 'lacking' issue is time. I'm having a quite heavy schedule to meet, but i'm still trying my best. The driver code is being deing developed on the svn, so those who think that they have the talent and knowledge to fill in the gaps at times for nicklas or me, just go ahead, make a checkout, write it, send us the patch :)
I'm very glad to see that the code from nicklas is very well shaped. It's nicely readable and understandable. To the others: don't be afraid of the kernel driver code. C code is still c code, the minor fact that you can totally crash your machine by using this doesn't make it all that special or deadly (your machine has crashed before and will also crash in the future, giving yourself the pleasure to do it by yourself at least once shouldn't be denied) :p
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I don't have the skills to help writing the driver (I even don't know how to write a code in C) but I am pleased to try to help you by testing the driver on my machine (even if I'm going to have few time in the near future too). My webcam is not a DC1125 but a STK1135, I'm interrested in this project because those webcams are likely to be very similar.
I downloaded Nicklas' driver on the following webpage : http://www.progweb.com/modules/webcam/driver/ I downloaded all the files, then changed a311 into a821 in stk1125.h (to try to adapt the driver to my webcam). Then I compiled the driver and copied all the .o and .ko files in /lib/modules/2.6.19/kernel/drivers/usb/image.
When I try to load the module by typing sudo modprobe -v stk1125, the answer is FATAL: Module stk1125 not found. And yet, when I type only modprobe -v stk then TAB, it completes the name fine... What can be the problem ? Did I install the driver the right way ?
My distribution is Ubuntu.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
If I remember correctly, you need to 'sudo depmod' to get it work, it updates some symbol tables so your system comes aware of this new module. And you should only need *.ko in your /lib/modules/..., not the *.o.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Thanks Simo, that was the solution. So here is exactly what I did :
1-Change a311 into a821 in stk1125.h to adapt the driver for my webcam
2-make
3-Copy stk1125.ko in /lib/modules/2.6.19/kernel/drivers/usb/image
4-sudo depmod
5-sudo modprobe -v stk1125
Now the driver is loaded successfully but I still don't manage to obtain any image.
When I type dmesg after having loaded the driver, here is the result :
# dmesg
[ 2147.792000] stk1125: usb_stk1125_init: Syntek USB2.0 webcam driver startup
[ 2147.840000] stk1125: Syntek USB2.0 - DC-1125 based webcam found.
[ 2147.840000] stk1125: Release: 0005
[ 2147.840000] stk1125: Number of interfaces : 1
[ 2147.956000] usb 5-8: reset high speed USB device using ehci_hcd and address 5
[ 2148.088000] stk1125: Initialize USB2.0 Syntek Camera
[ 2148.092000] stk1125: Loop 1 : Read 0x0000 = 24 %%%%% This line 16 times
[ 2148.104000] stk1125: Loop 2 : Read 0x0000 = 24 %%%%% This line 16 times
[ 2148.120000] stk1125: Loop 3 : Read 0x0000 = 24 %%%%% This line 16 times
[ 2148.132000] stk1125: dev_stk1125_configure_device : 0
[ 2148.200000] stk1125: dev_stk1125_configure_device : 1
[ 2148.268000] stk1125: dev_stk1125_configure_device : 2
[ 2148.336000] stk1125: Check device return error (0x0201 = 08) !
[ 2148.340000] stk1125: dev_stk1125_configure_device : 3
[ 2148.408000] stk1125: dev_stk1125_configure_device : 4
[ 2148.476000] stk1125: dev_stk1125_configure_device : 5
[ 2148.548000] stk1125: Check device return error (0x0201 = 08) !
[ 2148.548000] stk1125: dev_stk1125_configure_device : 6
[ 2148.620000] stk1125: Check device return error (0x0201 = 08) !
[ 2148.620000] stk1125: dev_stk1125_configure_device : 7
[ 2148.692000] stk1125: Check device return error (0x0201 = 08) !
[ 2148.696000] stk1125: dev_stk1125_configure_device : 8
[ 2148.700000] stk1125: Check device return error (0x0201 = 0C) !
[ 2148.700000] stk1125: Load microcode fail !
[ 2148.700000] stk1125: SET FEATURE
[ 2148.700000] stk1125: Syntek USB2.0 Camera is ready
[ 2148.704000] stk1125: Syntek USB2.0 Camera is now controlling video device /dev/video0
[ 2148.704000] usbcore: registered new interface driver usb_stk1125_driver
[ 2148.704000] stk1125: v0.0.1 : Syntek USB Video Camera
When launching camorama, the green LED near the webcam turns on but an error message appears : Unable to capture image
I tried with amsn too : the webcam is well detected but no image.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Will the driver work with a previous kernel?
Running latest Ubuntu there won't be any kernel upgrade until April or so, and if I can avoid the hassle of building my own kernel I would be happy.
My current kernel is 2.6.17.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
No, you must compile a new kernel, at least 2.6.18. The driver is not compatible with 2.6.17 (I tried and it cannot be loaded). The latest kernel is 2.6.19.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The steps of development are for a minimal usage :
1°/ Detect the device
2°/ Init the device
3°/ Get URB from device (the data from the camera)
4°/ Decompress the data
5°/ Send the data to videodev module
For the moment, 1, 2 and 3 is OK
(look : stk1125: Frame buffer overflow !)
Now, I have to decompress and convert the data for the videodev module (V4L)
By the way, Camorama uses V4L API v1
And XawTV uses V4L API v2.
I have decided to support V4L API v1 and v2.
Nicklas
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Thanks for the hint, like that Camorama finds the device, and it actually freezes on a " frame buffer overflow " (according to dmesg). OK, so no image, that's normal because the driver is not yet ready. Thanks very much for this great work, if you need some logfiles or so, I can provide you some.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
All the afraid thoughts of the projects deadness are quite far from the truth. We'll keep working until we get this thing running and we're not that far away from our goal, at least on the very basic level using the resolution 640x480. Right now our biggest 'lacking' issue is time. I'm having a quite heavy schedule to meet, but i'm still trying my best. The driver code is being deing developed on the svn, so those who think that they have the talent and knowledge to fill in the gaps at times for nicklas or me, just go ahead, make a checkout, write it, send us the patch :)
I'm very glad to see that the code from nicklas is very well shaped. It's nicely readable and understandable. To the others: don't be afraid of the kernel driver code. C code is still c code, the minor fact that you can totally crash your machine by using this doesn't make it all that special or deadly (your machine has crashed before and will also crash in the future, giving yourself the pleasure to do it by yourself at least once shouldn't be denied) :p
Hi !
I don't have the skills to help writing the driver (I even don't know how to write a code in C) but I am pleased to try to help you by testing the driver on my machine (even if I'm going to have few time in the near future too). My webcam is not a DC1125 but a STK1135, I'm interrested in this project because those webcams are likely to be very similar.
I downloaded Nicklas' driver on the following webpage : http://www.progweb.com/modules/webcam/driver/ I downloaded all the files, then changed a311 into a821 in stk1125.h (to try to adapt the driver to my webcam). Then I compiled the driver and copied all the .o and .ko files in /lib/modules/2.6.19/kernel/drivers/usb/image.
When I try to load the module by typing sudo modprobe -v stk1125, the answer is FATAL: Module stk1125 not found. And yet, when I type only modprobe -v stk then TAB, it completes the name fine... What can be the problem ? Did I install the driver the right way ?
My distribution is Ubuntu.
If I remember correctly, you need to 'sudo depmod' to get it work, it updates some symbol tables so your system comes aware of this new module. And you should only need *.ko in your /lib/modules/..., not the *.o.
Thanks Simo, that was the solution. So here is exactly what I did :
1-Change a311 into a821 in stk1125.h to adapt the driver for my webcam
2-make
3-Copy stk1125.ko in /lib/modules/2.6.19/kernel/drivers/usb/image
4-sudo depmod
5-sudo modprobe -v stk1125
Now the driver is loaded successfully but I still don't manage to obtain any image.
When I type dmesg after having loaded the driver, here is the result :
# dmesg
[ 2147.792000] stk1125: usb_stk1125_init: Syntek USB2.0 webcam driver startup
[ 2147.840000] stk1125: Syntek USB2.0 - DC-1125 based webcam found.
[ 2147.840000] stk1125: Release: 0005
[ 2147.840000] stk1125: Number of interfaces : 1
[ 2147.956000] usb 5-8: reset high speed USB device using ehci_hcd and address 5
[ 2148.088000] stk1125: Initialize USB2.0 Syntek Camera
[ 2148.092000] stk1125: Loop 1 : Read 0x0000 = 24 %%%%% This line 16 times
[ 2148.104000] stk1125: Loop 2 : Read 0x0000 = 24 %%%%% This line 16 times
[ 2148.120000] stk1125: Loop 3 : Read 0x0000 = 24 %%%%% This line 16 times
[ 2148.132000] stk1125: dev_stk1125_configure_device : 0
[ 2148.200000] stk1125: dev_stk1125_configure_device : 1
[ 2148.268000] stk1125: dev_stk1125_configure_device : 2
[ 2148.336000] stk1125: Check device return error (0x0201 = 08) !
[ 2148.340000] stk1125: dev_stk1125_configure_device : 3
[ 2148.408000] stk1125: dev_stk1125_configure_device : 4
[ 2148.476000] stk1125: dev_stk1125_configure_device : 5
[ 2148.548000] stk1125: Check device return error (0x0201 = 08) !
[ 2148.548000] stk1125: dev_stk1125_configure_device : 6
[ 2148.620000] stk1125: Check device return error (0x0201 = 08) !
[ 2148.620000] stk1125: dev_stk1125_configure_device : 7
[ 2148.692000] stk1125: Check device return error (0x0201 = 08) !
[ 2148.696000] stk1125: dev_stk1125_configure_device : 8
[ 2148.700000] stk1125: Check device return error (0x0201 = 0C) !
[ 2148.700000] stk1125: Load microcode fail !
[ 2148.700000] stk1125: SET FEATURE
[ 2148.700000] stk1125: Syntek USB2.0 Camera is ready
[ 2148.704000] stk1125: Syntek USB2.0 Camera is now controlling video device /dev/video0
[ 2148.704000] usbcore: registered new interface driver usb_stk1125_driver
[ 2148.704000] stk1125: v0.0.1 : Syntek USB Video Camera
When launching camorama, the green LED near the webcam turns on but an error message appears : Unable to capture image
I tried with amsn too : the webcam is well detected but no image.
Hey,
You should have to use the driver present in the SVN repository...
I'm going to work on the driver, then post a new revision.
Now, I work with the kernel 2.6.19
Nicklas
Will the driver work with a previous kernel?
Running latest Ubuntu there won't be any kernel upgrade until April or so, and if I can avoid the hassle of building my own kernel I would be happy.
My current kernel is 2.6.17.
No, you must compile a new kernel, at least 2.6.18. The driver is not compatible with 2.6.17 (I tried and it cannot be loaded). The latest kernel is 2.6.19.
Thanks Nicklas, I didn't realize that I was testing an old version. I downloaded the new files here : http://syntekdriver.svn.sourceforge.net/viewvc/syntekdriver/trunk/driver/
Is that the right place ?
I did exactly the same steps than in my yesterday's message. The results of dmesg and amsn are exactly the same. Camorama doesn't manage to connect to the webcam ("could not connect to video device. Please check connection") Here is the result of dmesg after having run camorama (the first 12 lines appear several times)
[ 1757.157000] stk1125: usb_stk1125_isoc_handler
[ 1757.157000] stk1125: Frame buffer overflow !
[ 1757.157000] stk1125: Frame buffer overflow !
[ 1757.157000] stk1125: Frame buffer overflow !
[ 1757.157000] stk1125: Frame buffer overflow !
[ 1757.157000] stk1125: Frame buffer overflow !
[ 1757.157000] stk1125: Frame buffer overflow !
[ 1757.157000] stk1125: Frame buffer overflow !
[ 1757.157000] stk1125: Frame buffer overflow !
[ 1757.157000] stk1125: Frame buffer overflow !
[ 1757.157000] stk1125: Frame buffer overflow !
[ 1757.159000] stk1125: usb_stk1125_isoc_handler
[ 1757.159000] stk1125: URB unlinked synchronuously !
[ 1757.160000] stk1125: usb_stk1125_isoc_handler
[ 1757.160000] stk1125: URB unlinked synchronuously !
[ 1757.160000] stk1125: Free buffers
With Camorama :
camorama -D --width=640 --height=480
It's good :)
Camorama have to stay blocked !
The steps of development are for a minimal usage :
1°/ Detect the device
2°/ Init the device
3°/ Get URB from device (the data from the camera)
4°/ Decompress the data
5°/ Send the data to videodev module
For the moment, 1, 2 and 3 is OK
(look : stk1125: Frame buffer overflow !)
Now, I have to decompress and convert the data for the videodev module (V4L)
By the way, Camorama uses V4L API v1
And XawTV uses V4L API v2.
I have decided to support V4L API v1 and v2.
Nicklas
Hi Nicklas !
Thanks for the hint, like that Camorama finds the device, and it actually freezes on a " frame buffer overflow " (according to dmesg). OK, so no image, that's normal because the driver is not yet ready. Thanks very much for this great work, if you need some logfiles or so, I can provide you some.