Laurent,

>
> > Is there a way to make these changes when mapping the controls, or do
> they
> > have to be coded in the driver itself ?
>
> Switching the Pan Reset and Tilt Reset from integers to button should
> require
> a modification of the logitech.xml file only (although it might also
> trigger
> bugs in yet unused code paths of libwebcam/uvcdynctrl).


I gave that a go:
I changed  the v4l2_type element from V4L2_CTRL_TYPE_INTEGER to
V4L2_CTRL_TYPE_BUTTON for both the Pan Reset and Tilt Reset mappings.
Not sure how to get uvcvideo to unmap existing controls, so I rmmod/modprobe
(trace=1023) it, and confirmed it lacks these mappings. Then I had to modify
libwebcam to support the V4L2_CTRL_TYPE_BUTTON. To be precise, libwebcam
already had the code for that but it was commented out (lines 446 to 456 in
dynctrl.c). I then imported the dynamic controls with uvcdynctrl -i, and it
went fine. Pan & Tilt Reset are reported as buttons, but setting a value on
them does nothing and these lines are added to syslog:

 kernel: [57399.195259] v4l2 ioctl VIDIOC_S_CTRL, dir=rw (0xc008561c)
 kernel: [57399.202594] uvcvideo: Control 9/2 failure change len 6.

I m not sure what the implications of the change to V4L2_CTRL_TYPE_BUTTON
are (besides modifying the reported v4l2_queryctrl struct) within the driver
and the way it send control values to the device. Is it anything that can be
fixed ? If so how can I help ?
Gilles
_______________________________________________
Linux-uvc-devel mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/linux-uvc-devel

Reply via email to