udev rules for webcam

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all!

I've got an old eeepc 901 set up with Fedora 20, in a captive situation
where it operates a USB web cam (not the built-in one, but something a
good deal better, though modestly priced) snapping an image once per
minute.

Unfortunately, on the rare occasions when the eeepc gets rebooted, the
location in /dev of the particular web cam I'm interested in sometimes
changes from /dev/video0 to /dev/video1, or sometimes the other way.

I was looking to see if I could grope /proc files to find out which 
one was the camera I'm interested in, so the script that runs it
could adapt.

not finding anything on that, I hit on writing a udev rule for the
USB device to make sure it appeared as a predictable /dev/video<x>.

So, I found a bunch of advice on the web, and tried two rather
different udev rules, neither of which works in any way I can confirm.
Here's one of 'em:

lsusb:
Bus 001 Device 002: ID 046d:0825 Logitech, Inc. Webcam C270

so, according to one of the recipes I found, if I make a rule like this
it should work:

SUBSYSTEM=="video4linux", SUBSYSTEM=="usb", ATTRS{idVendor}=="0x046d", ATTRS{idProduct}=="0x0825", SYMLINK+="logitechcam"

if I understand it, this should make the camera appear as "/dev/logitechcam".

If I'm off-base here I hope someone will straighten me out.

this rule is stored in a file in /etc/udev/rules.d/25<stuff>.rules.

unplug/replug the camera elicits no change, and no /dev/logitechcam node,
either. neither does a reboot.

Advice will be gladly accepted! Thanks in advance.

Fred
-- 
---- Fred Smith -- fredex@xxxxxxxxxxxxxxxxxxxxxx -----------------------------
    "Not everyone who says to me, 'Lord, Lord,' will enter the kingdom of
     heaven, but only he who does the will of my Father who is in heaven."
------------------------------ Matthew 7:21 (niv) -----------------------------
-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Fedora Code of Conduct: http://fedoraproject.org/code-of-conduct
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
Have a question? Ask away: http://ask.fedoraproject.org




[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux