You are not logged in.

#1 2006-10-09 18:31:33

slackhack
Member
Registered: 2004-06-30
Posts: 738

user can't access camera anymore, root still can [SOLVED]

since the last udev update, i can't access my camera anymore as user. gtkam gives this error:

An error occurred in the io-library ('Could not find the requested device on the USB port'): Could not find USB device (class 0x6, subclass 0x1, protocol 0x1). Make sure this device is connected to the computer.

the camera is a canon A75, vendor 04a9, product ID 305b. lsusb says it's connected to Bus 001 Device 011. i added that info to a custom 010.udev.rules file, but i don't know where to add the USB info. :?: user is in the camera group, btw.

ACTION=="add", SYSFS{idVendor}=="04a9", SYSFS{idProduct}=="305b", RUN+="/bin/chmod o-rwx $env{DEVICE}"
ACTION=="add", SYSFS{idVendor}=="04a9", SYSFS{idProduct}=="305b", RUN+="/bin/chgrp users $env{DEVICE}"
ACTION=="add", SYSFS{idVendor}=="04a9", SYSFS{idProduct}=="305b", RUN+="/bin/chmod g+rw $env{DEVICE}", OPTIONS="last_rule"

thanks for any help.


>>edit: turns out root can't access the photos, either. the camera is detected and the photos load and show up in gtkam, but when i try to save them i get an error, e.g., "Problem getting 'IMG_0332.JPG' from folder '/store_00010001/DCIM/103CANON'."  wtf? :?:


>>edit2: okay, i got it by adding

SYSFS{idVendor}=="04a9", SYSFS{idProduct}=="305b", GROUP:="camera"

to a 00.gphoto.udev.rules file and restarting udev (i never noticed b4, but no script? i had to kill udevd and do /usr/sbin/udevd -d).

is that just a kluge fix though? i don't know anything about udev to know if that's the best way to do it, or if there's a better, more "correct" way. i just want to be able to access the camera from now on without having to change rules or mess around with udev anymore (i thought the point of udev was to have transparency to the user? roll ). thanks.


>> edit again: i love having conversations with myself. lol

okay, i didn't even notice the gphoto.rules file bfore, but i just added the information for my camera to the file, restarted udev, and it seems to work. if the maintainer wants to add the info for canon A75 to the file, the line is:

ATTRS{idVendor}=="04a9", ATTRS{idProduct}=="305b", GROUP="camera"

Offline

#2 2006-10-10 11:57:17

lanrat
Member
From: Poland
Registered: 2003-10-28
Posts: 1,274

Re: user can't access camera anymore, root still can [SOLVED]

Nice conversation :-)

If your camera isn't already in gphoto.rules you should report it to package maintainer (feature request) and/or gphoto devs.

I wouldn't modify standard gphoto.rules. I'd rather put this rule in /etc/udev/rules.d/00.udev.rules:

ATTRS{idVendor}=="04a9", ATTRS{idProduct}=="305b", GROUP:="camera"

to avoid overwriting after next update.

For restarting udev there is /etc/start_udev (or udev_start or something like this - I can't remember it :-))

Offline

#3 2006-10-10 13:16:06

slackhack
Member
Registered: 2004-06-30
Posts: 738

Re: user can't access camera anymore, root still can [SOLVED]

lanrat wrote:

Nice conversation :-)

If your camera isn't already in gphoto.rules you should report it to package maintainer (feature request) and/or gphoto devs.

I wouldn't modify standard gphoto.rules. I'd rather put this rule in /etc/udev/rules.d/00.udev.rules:

ATTRS{idVendor}=="04a9", ATTRS{idProduct}=="305b", GROUP:="camera"

to avoid overwriting after next update.

For restarting udev there is /etc/start_udev (or udev_start or something like this - I can't remember it :-))

thanks, it is /etc/start_udev - i was looking in /etc/rc.d. yikes
i moved it back to 00.gphoto.rules so it won't get overwritten.
now that it's verified working in the standard rules, i'll make a report to the devs to add the cam there.

is your method for doing this in the wiki? i pretty much only figured out how to do it by reading your posts. if you have time, i think it would be a great wiki item.  8)

Offline

#4 2006-10-11 10:18:03

lanrat
Member
From: Poland
Registered: 2003-10-28
Posts: 1,274

Re: user can't access camera anymore, root still can [SOLVED]

It's not a "method" really :-) It's just how udev works 8)

At the moment I'm very busy but I have it on my to-do list. I'll have to review udev related information which is currently spread all over the wiki articles and write maybe one article groupping all examples and FAQs etc. Unless of course they'll release another version in a few days which completly changes rules syntax and processing ;-)

Offline

#5 2006-12-02 00:23:59

gee
Member
Registered: 2006-11-29
Posts: 251

Re: user can't access camera anymore, root still can [SOLVED]

thanks for the topic, it helped me with my new camera smile

Offline

Board footer

Powered by FluxBB