Hi,

I'm stuck on a project and I wondered if any of you kind chaps might be able 
to help? (platform = kernel 2.4.16 using usb-uhci)

I'm writing a device driver (GPL) for the PrimaScan icam320 webcam (based on 
the existing driver for dabusb). I'm using sniffusb 0.13 to intercept the 
windows<->webcam. I've got the device registered, probed and initialised by 
sending the same control messages logged by sniff usb.

Now problems or errors until now.


Question 1. I'm submitting the ISO tranfer URBs which are all coming back 
(via completion handler) with the correct number of packets - but they are 
all empty. No errors, status is fine, frame count is increasing as expected 
... just no data. What's the best way to prove 100% that they're coming from 
the webcam? I'll happily patch the kernel to output extra diagnostics if 
necessary... Any suggestions?

Example hexdump from received packet data:
000000 00ff 0000 0000 0000 0000 0000 0000 0000
000010 0000 0000 0000 0000 0000 0000 0000 0000
*
000380 00ff 0000 0000 0000 0000 0000 0000 0000
000390 0000 0000 0000 0000 0000 0000 0000 0000
*
000700 00ff 0000 0000 0000 0000 0000 0000 0000
000710 0000 0000 0000 0000 0000 0000 0000 0000
*
000a80 00ff 0000 0000 0000 0000 0000 0000 0000
000a90 0000 0000 0000 0000 0000 0000 0000 0000
*
000e00 00ff 0000 0000 0000 0000 0000 0000 0000
000e10 0000 0000 0000 0000 0000 0000 0000 0000
*
001180 00ff 0000 0000 0000 0000 0000 0000 0000
001190 0000 0000 0000 0000 0000 0000 0000 0000

Question 2. Before the URB is passed to the completion handler, the urb->dev 
field is being nullified. What's the rational behind this? It causes 
dabusb.c to oops when calling "unsigned int pipe = usb_rcvisocpipe 
(purb->dev, _DABUSB_ISOPIPE);" Anyone else noticed this? Look like the 
driver in 2.4.16 is broke an no one noticed.

Question 3. SniffUSB starts the logfile with the output below, am I correct 
in assuming that this is the same as...

usb_set_configuration (usbdev, usbdev->config[0].bConfigurationValue)
and
usb_set_interface (s->usbdev, 0, 6);


UsbSnoop - IRP_MJ_INTERNAL_DEVICE_CONTROL, IOCTL_INTERNAL_USB_SUBMIT_URB

>>>>>>>URB 782 going down...
-- URB_FUNCTION_SELECT_INTERFACE:
!!! Hdr.Length is wrong! (is: 32, should be at least: 56)
  ConfigurationHandle     = 0xc2a122c0
  Interface: Length            = 0x00000024
  Interface: InterfaceNumber   = 0x00
  Interface: AlternateSetting  = 0x06
  Interface: Class             = 0xff
  Interface: SubClass          = 0x00
  Interface: Protocol          = 0x00
  Interface: InterfaceHandle   = 0xcc5ed5f0
  Interface: NumberOfPipes     = 0x00000001

<<<<<<< URB 782 coming back...
-- URB_FUNCTION_SELECT_INTERFACE:
!!! Hdr.Length is wrong! (is: 32, should be at least: 56)
  ConfigurationHandle     = 0xc2a122c0
  Interface: Length            = 0x00000024
  Interface: InterfaceNumber   = 0x00
  Interface: AlternateSetting  = 0x06
  Interface: Class             = 0xff
  Interface: SubClass          = 0x00
  Interface: Protocol          = 0x00
  Interface: InterfaceHandle   = 0xcc5e9d80
  Interface: NumberOfPipes     = 0x00000001
  Interface: Pipes[0] : MaximumPacketSize = 0x0380
  Interface: Pipes[0] : EndpointAddress   = 0x81
  Interface: Pipes[0] : Interval          = 0x01
  Interface: Pipes[0] : PipeType          = 0x01 (UsbdPipeTypeIsochronous)
  Interface: Pipes[0] : PipeHandle        = 0xcc5e9d98
  Interface: Pipes[0] : MaxTransferSize   = 0x00008000
  Interface: Pipes[0] : PipeFlags         = 0x00
UsbSnoop - IRP_MJ_INTERNAL_DEVICE_CONTROL, IOCTL_INTERNAL_USB_SUBMIT_URB

I know you're all busy but any advise/comments would be very welcome.

Thanks again,

Steve


_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to