You are not logged in.

#1 2006-04-14 07:09:25

rztka
Member
From: Czech Republic
Registered: 2006-03-10
Posts: 37

latest libgphoto2 - problem with canon camera

hi after libgphoto2 upgrade, f-spot/gtkam/gphoto cannot get a connection with my camera (canon powershot a75)... downgrade to previous version of libgphoto2 package fixed the problem...
should i submit a bug or something? (i'm a newbie to this but i would like to help - what should i do in such situation?)

thanks,
tereza

Offline

#2 2006-04-14 07:45:49

pressh
Developer/TU
From: Netherlands
Registered: 2005-08-14
Posts: 1,719

Re: latest libgphoto2 - problem with canon camera

rztka, can you rebuild libgphoto2 through abs and removing the gphoto2-2.1.99-canon_segv.patch patch. I just got it in the package as libghpoto2 does have problems with other canon cameras, but maybe it is giving problems to your camera ?
It might as well be a problem in the new libgphoto2 version, which needs another patch for your camera?

Also what exact errors do you get ? (preferebly use gphoto to get errors)

[edit] can you also try it as root. thanks

Offline

#3 2006-04-14 13:42:38

pressh
Developer/TU
From: Netherlands
Registered: 2005-08-14
Posts: 1,719

Re: latest libgphoto2 - problem with canon camera

My guess after all is that you have an empty gphoto.rules file ?
I submitted a bug about that.

Offline

#4 2006-04-14 15:31:11

rztka
Member
From: Czech Republic
Registered: 2006-03-10
Posts: 37

Re: latest libgphoto2 - problem with canon camera

normally i use f-spot, i just installed gphoto to see if the problem is with f-spot or with something else - i'm not familiar with gphoto but i tried to auto-detect camera as root and this works. then i made directory called photo, cd to it and run:
env LANG=C gphoto2 --debug --get-all-files

i got lots of these: (reading data from camera?camera was blinking..)

0cb0  e1 23 03 61 1f 31 6c f1-4a be 58 b4 44 5c 12 38  .#.a.1l.J.X.D.8
0cc0  ce 3a 8a 95 7d c7 78 df-42 d5 a1 0a a1 5f 03 b0  .:..}.x.B...._..
0cd0  03 d2 b3 ef 62 68 81 68-d8 b1 27 1b 4f 7f 7a 4c  ....bh.h..'.O.zL
0ce0  5a 18 b7 51 e7 cd 8e 40-c3 6b 70 3a 73 4c 75 22  Z..Q...@.kp:sLu"
0cf0  30 23 20 fa 1c d6 97 bc-6c 09 f3 bf 42 84 ba 60  0# .....l...B..`
0d00  90 2a 11 b9 53 a6 47 4a-a3 77 a7 aa b3 92 0c 6c  .*..S.GJ.w.....l
0d10  4f de 03 a9 f4 aa 53 d5-58 ce 71 4a f6 d8 a7 6d  O.....S.X.qJ...m0d20  01 56 42 e7 73 8e ca 05-43 1c 6a 03 48 fc 1d c4  .VB.s...C.j.H...
0d30  00 7b e3 db d2 9d ee 99-16 4a c9 7c c6 79 8d 2c  .{.......J.|.y.,
0d40  9e 71 05 fb e1 56 8b 9d-b1 c8 e4 e5 06 3e 5c 0c  .q...V.......>.
0d50  83 ec 6a 1d af 61 f3 5f-e4 36 d2 55 56 3e 63 95  ..j..a._.6.UV>c.
0d60  1b 7a 2a f0 c6 a3 b4 91-62 2c d8 2d 26 78 f9 8f  .z*.....b,.-&x..
0d70  02 af 5b 8d 4a 16 2d 99-0d d8 c1 1b 1c 1e 70 3a  ..[.J.-.......p:
0d80  52 4b 10 52 ce cc 76 2f-1f 29 a1 3d 47 34 ea 46  RK.R..v/.).=G4.F
0d90  cb ee 19 e4 a3 11 b7 1f-28 ea 69 b1 41 b0 ef 98  ........(.i.A...
0da0  e1 ff 00 84 20 c8 6f ad-1e 64 a8 ab 58 8e 3d f0  .... .o..d..X.=.
0db0  38 c4 7f 56 3d fd a9 cd-68 41 2c 7a b0 27 0a 69  8..V=...hA,z.'.i

but the end looks like that (and directory photo is empty of course):

21.054264 canon/usb.c(2): canon_usb_long_dialogue: total_data_size = 679369, bytes_received = 679360, read_bytes = 9 (0x9)
21.054293 gphoto2-port(2): Reading 9=0x9 bytes from port...
21.054909 gphoto2-port(3): Hexdump of 9 = 0x9 bytes follows:
0000  de c2 4d ca 5c bd 0f ff-d9                       ..M.....

21.054997 libgphoto2/gphoto2-filesys.c(2): Getting information about 'IMG_0832.JPG' in '/DCIM/108CANON'...
21.055372 canon/canon.c(3): gphoto2canonpath: converted '/DCIM/108CANON' to 'D:DCIM108CANON'
21.055398 canon/canon.c(2): canon_int_set_file_attributes() called for 'D:DCIM108CANON' 'IMG_0832.JPG', attributes 0x0
21.055432 canon/usb.c(2): canon_usb_set_file_attributes()
21.055444 canon/usb.c(2): canon_usb_set_file_attributes(): payload is 35=0x23 bytes; string length is 16=0x10
21.055460 canon/usb.c(2): canon_usb_dialogue() cmd 0xe 0x11 0x201 (Set file attributes)
21.055474 canon/usb.c(2): Payload :
21.055490 canon(3): Hexdump of 35 = 0x23 bytes follows:
0000  00 00 00 00 44 3a 5c 44-43 49 4d 5c 31 30 38 43  ....D:DCIM108C
0010  41 4e 4f 4e 00 49 4d 47-5f 30 38 33 32 2e 4a 50  ANON.IMG_0832.JP
0020  47 00 00               -                         G..

21.055510 gphoto2-port(2): Writing message (request=0x4 value=0x10 index=0x0 size=115=0x73)...
21.055526 gphoto2-port(3): Hexdump of 115 = 0x73 bytes follows:
0000  33 00 00 00 01 02 00 00-00 00 00 00 00 00 00 00  3...............
0010  00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00  ................
0020  00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00  ................
0030  00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00  ................
0040  02 00 00 00 0e 00 00 11-33 00 00 00 0d 00 00 00  ........3.......
0050  00 00 00 00 44 3a 5c 44-43 49 4d 5c 31 30 38 43  ....D:DCIM108C
0060  41 4e 4f 4e 00 49 4d 47-5f 30 38 33 32 2e 4a 50  ANON.IMG_0832.JP
0070  47 00 00               -                         G..

21.083921 gphoto2-port(2): Reading 64=0x40 bytes from port...
21.122061 gphoto2-port(3): Hexdump of 64 = 0x40 bytes follows:
0000  14 00 00 00 01 03 00 00-00 00 00 00 00 00 00 00  ................
0010  00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00  ................
0020  00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00  ................
0030  00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00  ................

21.122112 canon/usb.c(2): canon_usb_dialogue: camera reports 0x14 bytes (0x54 total)
21.122127 gphoto2-port(2): Reading 20=0x14 bytes from port...
21.122880 gphoto2-port(3): Hexdump of 20 = 0x14 bytes follows:
0000  02 00 00 00 0e 00 00 21-14 00 00 00 0d 00 00 00  .......!........
0010  00 00 00 00            -                         ....

21.122958 libgphoto2/gphoto2-filesys.c(2): Adding file 'IMG_0832.JPG' to folder '/DCIM/108CANON' (type 1)...
21.123328 libgphoto2/gphoto2-filesys.c(2): Adding file 'IMG_0832.JPG' from folder '/DCIM/108CANON' to the fscache LRU list (type 1)...
21.123537 libgphoto2/gphoto2-filesys.c(2): File 'IMG_0832.JPG' from folder '/DCIM/108CANON' added in fscache LRU list.
21.123551 libgphoto2/gphoto2-filesys.c(2): Checking fscache LRU list integrity...
21.123562 libgphoto2/gphoto2-filesys.c(2): fscache LRU list ok with 1 items (679369 bytes)
21.123584 libgphoto2/gphoto2-filesys.c(2): File does not contain mtime. Trying information on the file...
21.123600 libgphoto2/gphoto2-filesys.c(2): Getting information about 'IMG_0832.JPG' in '/DCIM/108CANON'...
gphoto2: symbol lookup error: gphoto2: undefined symbol: GP_SYSTEM_IS_FILE

concearning the f-spot, running it as a root i can get the pictures from camera.. but as a normal user i get this:

item ImportCommand+SourceItem
item ImportCommand+SourceItem
Testing gphoto path = usb:
PortInfo Universal Serial Bus, usb:
Error USBClaim: LibGPhoto2.GPhotoException: Exception of type LibGPhoto2.GPhotoException was thrown.
in <0x00031> LibGPhoto2.Error:CheckError (ErrorCode error)
in <0x00053> LibGPhoto2.Camera:Init (LibGPhoto2.Context context)
in <0x00020> GPhotoCamera:InitializeCamera ()
in <0x001dd> MainWindow:ImportCamera (System.String camera_device)
cleanup context
cleanup context
cleanup context
cleanup context
cleanup context
cleanup context

so maybe some problem with priviledges?
i wish i know what all this means wink

my gphoto.rules is not empty, there are two lines:
SUBSYSTEM!="usb_device", ACTION!="add", GOTO="libgphoto_rules_end"
LABEL="libgphoto_rules_end"

and you suggest to remove the .patch file and rebuild the libgphoto2 package right? i will try it...

Offline

#5 2006-04-14 16:09:27

rztka
Member
From: Czech Republic
Registered: 2006-03-10
Posts: 37

Re: latest libgphoto2 - problem with canon camera

rztka wrote:

and you suggest to remove the .patch file and rebuild the libgphoto2 package right? i will try it...

hmmm i'm not sure how to do this.. :oops:

well i found something on internet about libgphoto2 and the problem with canon cameras, including my Power Shot A75 (they are detected only when running gphoto as root and so on.. it seems like the problem i have) and about the patch... so the problem with the latest package must be the patch, right? the previous one works so i guess i will stick with that and wait for another upgrade.. what do you think?

and thanks for your help pressh!

Offline

#6 2006-04-16 05:09:58

EmbraceThePenguin
Member
From: New Mexico, USA
Registered: 2004-08-09
Posts: 197

Re: latest libgphoto2 - problem with canon camera

My Sony Mavica is having this problem too...

Permissions on the devices are not correct...

ls -lR /proc/bus/usb
/proc/bus/usb:
total 0
dr-xr-xr-x  2 root root 0 2006-04-15 14:58 001
dr-xr-xr-x  2 root root 0 2006-04-15 14:58 002
-r--r--r--  1 root root 0 2006-04-15 23:08 devices

/proc/bus/usb/001:
total 0
-rw-r--r--  1 root root 43 2006-04-15 14:58 001
-rw-r--r--  1 root root 52 2006-04-15 14:58 002
-rw-r--r--  1 root root 52 2006-04-15 14:58 003

/proc/bus/usb/002:
total 0
-rw-r--r--  1 root root 43 2006-04-15 14:58 001
-rw-r--r--  1 root root 43 2006-04-15 14:58 002
-rw-r--r--  1 root root 59 2006-04-15 14:58 005
-rw-r--r--  1 root root 57 2006-04-15 14:58 006
-rw-r--r--  1 root root 57 2006-04-15 23:08 008

Any idea when this will be fixed?

Thanks!!!

Joe

Offline

#7 2006-04-16 07:34:44

starthis
Member
Registered: 2004-12-25
Posts: 46

Re: latest libgphoto2 - problem with canon camera

I also have problems to access my canon digital camera (Powershot A20).
I tried the suggested patch in this thread but no result.

The camera worked fine before with the 3 udev lines mentionned elsewhere in the forum.

gphoto2 is unable to find any camera devices. When looking around in my system to see if the usb device was actually detected, I got confused   :?

In 'cat /proc/bus/usb/devices' I find the camera device :

T:  Bus=02 Lev=01 Prnt=01 Port=01 Cnt=02 Dev#=  6 Spd=12  MxCh= 0
D:  Ver= 1.00 Cls=ff(vend.) Sub=ff Prot=ff MxPS=32 #Cfgs=  1
P:  Vendor=04a9 ProdID=304e Rev= 0.01
S:  Manufacturer=Canon Inc.
S:  Product=PowerShot A20
C:* #Ifs= 1 Cfg#= 1 Atr=40 MxPwr=100mA
I:  If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none)
E:  Ad=81(I) Atr=02(Bulk) MxPS=  64 Ivl=0ms
E:  Ad=02(O) Atr=02(Bulk) MxPS=  64 Ivl=0ms
E:  Ad=83(I) Atr=03(Int.) MxPS=  64 Ivl=96ms

but the lsusb command doesn't show the camera :

Bus 002 Device 003: ID 046d:c00c Logitech, Inc. Optical Wheel Mouse
Bus 002 Device 001: ID 0000:0000
Bus 002 Device 002: ID 0451:1020 Texas Instruments, Inc.
Bus 001 Device 001: ID 0000:0000
Bus 003 Device 001: ID 0000:0000

What is the difference between both, and which one should I take into account?

btw The updated libgphoto package didn't solve the problem either.

Offline

#8 2006-04-16 18:19:13

miko
Member
From: Poland
Registered: 2006-04-16
Posts: 49

Re: latest libgphoto2 - problem with canon camera

Hello, I had working digikam with EOS 350D until 03th of april (this was last time it worked). Then I made some package upgrades and now it does not work.
It does not connect, and cannot detect the camera. gtkam, however, works fine.
I am getting following output from gphoto2:

# gphoto2 --auto-detect
Model                          Port                                             
----------------------------------------------------------
Canon EOS 350D (PTP mode)      usb:            

I have recompiled libgphoto2 without the latest patch, but it did not help. Is this a known issue?

miko

Offline

#9 2006-04-16 19:20:06

miko
Member
From: Poland
Registered: 2006-04-16
Posts: 49

Re: latest libgphoto2 - problem with canon camera

I have recompiled libgphoto2 without the latest patch, but it did not help. Is this a known issue?

Sorry for answering myself. I downgraded libgphoto from 2.1.99 to 2.1.6 and digikam started to work. So I guess digikam-0.8.1 should depend on libgphoto2-2.1.6.

miko

Offline

#10 2006-04-17 16:51:41

EmbraceThePenguin
Member
From: New Mexico, USA
Registered: 2004-08-09
Posts: 197

Re: latest libgphoto2 - problem with canon camera

miko wrote:

I have recompiled libgphoto2 without the latest patch, but it did not help. Is this a known issue?

Sorry for answering myself. I downgraded libgphoto from 2.1.99 to 2.1.6 and digikam started to work. So I guess digikam-0.8.1 should depend on libgphoto2-2.1.6.

miko

Well, I suppose I can downgrade, but I really hate to manually manage packages.

Any news as to when this will get fixed...

Joe

Offline

#11 2006-04-17 17:24:28

test1000
Member
Registered: 2005-04-03
Posts: 834

Re: latest libgphoto2 - problem with canon camera

you could put libgphoto in IgnorePkg in /etc/pacman.conf.
Anyway i just updated libgphoto and i have always needed to use root; i just assumed it was necessary.

So I sat up a sudo "rule" like:
%users localhostdude=NOPASSWD:/usr/bin/gtkam
which work great, and then I can just sudo gtkam to get to my pictures.

oh and i have a canon powershot S80


KISS = "It can scarcely be denied that the supreme goal of all theory is to make the irreducible basic elements as simple and as few as possible without having to surrender the adequate representation of a single datum of experience." - Albert Einstein

Offline

#12 2006-04-17 17:54:17

EmbraceThePenguin
Member
From: New Mexico, USA
Registered: 2004-08-09
Posts: 197

Re: latest libgphoto2 - problem with canon camera

test1000 wrote:

you could put libgphoto in IgnorePkg in /etc/pacman.conf.
Anyway i just updated libgphoto and i have always needed to use root; i just assumed it was necessary.

So I sat up a sudo "rule" like:
%users localhostdude=NOPASSWD:/usr/bin/gtkam
which work great, and then I can just sudo gtkam to get to my pictures.

oh and i have a canon powershot S80

Well, it worked before the last update as it should; so a normal user could access the devices (Either in the camera group, or if you followed the Wiki, the users group).

I have never needed Root to access my camera (Sony Mavica). I prefer to NOT use root for day to day activities.

If this is something that is not going to get fixed, then I will manage the libgphoto2 software (I have not seen any more from the package maintainers on this) but I, and others I'm sure, would prefer the package to be fixed as it was.

Joe

Offline

#13 2006-04-19 14:32:44

sebcactus
Member
From: Germany
Registered: 2005-01-27
Posts: 277

Re: latest libgphoto2 - problem with canon camera

A /etc/udev/rules.d/gphoto.rules with only two lines is considered as empty (you don't have any rules). Normally, there are plenty of lines for many cameras.

Mine (Canon G3) for example is:

SUBSYSTEM!="usb_device", ACTION!="add", GOTO="libgphoto_rules_end"
# Canon PowerShot G3 (PTP mode)
SYSFS{idVendor}=="04a9", SYSFS{idProduct}=="306f", GROUP="camera"
LABEL="libgphoto_rules_end"

You can find the information (the SYSFS{idProduct} and SYSFS{idVendor} of your camera using

udevinfo -a -p  /bus/usb/devices/usb2/2-1/2-1.1

To get the right usb numbers, you can plug your camera and use

sudo cat /var/log/messages.log

Edit: you can also get a right gphoto.rules file from ABS according to
http://bbs.archlinux.org/viewtopic.php?t=20662

Hope it helps

Offline

#14 2006-04-19 14:55:00

pressh
Developer/TU
From: Netherlands
Registered: 2005-08-14
Posts: 1,719

Re: latest libgphoto2 - problem with canon camera

marmotte wrote:

Edit: you can also get a right gphoto.rules file from ABS according to
http://bbs.archlinux.org/viewtopic.php?t=20662

Hope it helps

The empty gphoto.rules file was a bug and has been corrected in the latest version.

Offline

#15 2006-04-19 15:14:10

EmbraceThePenguin
Member
From: New Mexico, USA
Registered: 2004-08-09
Posts: 197

Re: latest libgphoto2 - problem with canon camera

I installed the new version after a system rebuild last night and have the -2 version of libgphoto2, however, I am still having the same issue.

I can see the camera in dmesg, but no permission changes in the usb filesystem and I cant see the camera in Digikam.

Where else can I look here to get this fixed?

Thanks!!!

Joe

Offline

#16 2006-04-20 14:08:17

sebcactus
Member
From: Germany
Registered: 2005-01-27
Posts: 277

Re: latest libgphoto2 - problem with canon camera

Is your /etc/rules.d/gphoto.rules full ?

Offline

#17 2006-04-20 14:15:46

EmbraceThePenguin
Member
From: New Mexico, USA
Registered: 2004-08-09
Posts: 197

Re: latest libgphoto2 - problem with canon camera

marmotte wrote:

Is your /etc/rules.d/gphoto.rules full ?

Yeah, they are full...

For an update,

I was e-mailing tpowa last night, and he found out what the issue was...

Basically, he made some patches for libusb that changed the permissions to /dev/usb/xxx, instead of /prob/usb/xxx (Where Digikam likes them to be).

So, it appears to be a config/patch issue and not something with the software. However, Digikam might need to be rebuilt, not sure. I am still waiting to hear back from him after troubleshooting some stuff last night.

Thanks!!!

Joe

Offline

#18 2006-04-22 08:38:30

Dieter
Member
From: Germany
Registered: 2005-10-13
Posts: 140

Re: latest libgphoto2 - problem with canon camera

libgphoto2 ist back to 2.1.6-6 here, but I still cannot access my Canon A40 with digikam. Which additional steps are needed to enable image downloading from the camera with digikam again?

The access to the camera is needed for work; no card reader and no Windows OS is installed (perhaps I can try with the Arch64 on another partition). If I do not get it fixed soon, I will risk trouble with my boss.

TIA, Dieter

Offline

#19 2006-04-22 09:49:59

jochen
Member
From: Germany
Registered: 2004-06-01
Posts: 102

Re: latest libgphoto2 - problem with canon camera

Hi Dieter,

did you reboot after reinstalling libgphoto2-2.1.6-6? Also make sure you're member of group audio.

Offline

#20 2006-04-22 10:44:23

Dieter
Member
From: Germany
Registered: 2005-10-13
Posts: 140

Re: latest libgphoto2 - problem with canon camera

yes, I rebootet. The user is in group camera (that's what you meant, not audio). The camera is recognized by automatic detection, but connection to the camera for downloading the stored images works only from time to time (sometimes it does, sometimes not).
During the last 5 tries it worked 4 times, one time digikam couldn't connect.

Offline

#21 2006-04-22 20:23:03

pressh
Developer/TU
From: Netherlands
Registered: 2005-08-14
Posts: 1,719

Re: latest libgphoto2 - problem with canon camera

Dieter wrote:

During the last 5 tries it worked 4 times, one time digikam couldn't connect.

I guess this cannot solely be blamed on libgphoto. libgphoto is just a lib from which applications read how to access the camera. It cannot randomly pick a way to connect to your camera.
There should be something else which makes digikam to choose to connect or not to connect.
You should try to get the output digikam gives when it desides not to connect. Without error messages, logs, etc there is no way one can know what is really going on here.

Offline

#22 2006-04-23 10:32:39

mic64
Member
Registered: 2005-03-03
Posts: 173

Re: latest libgphoto2 - problem with canon camera

with the latest update I´m getting this

error: archive libgphoto2-2.1.6-6.pkg.tar.gz is corrupted

EDIT: after a -Scc and a new update its ok

mic

Offline

#23 2006-04-23 19:48:24

Dieter
Member
From: Germany
Registered: 2005-10-13
Posts: 140

Re: latest libgphoto2 - problem with canon camera

You should try to get the output digikam gives when it desides not to connect

Please tell me how I can get additional logging information. I can't find anything in the /var/log/* files. Thanks!

Offline

#24 2006-04-24 09:25:42

sebcactus
Member
From: Germany
Registered: 2005-01-27
Posts: 277

Re: latest libgphoto2 - problem with canon camera

Start it from a terminal

Offline

#25 2006-04-25 13:53:06

funkmuscle
Member
Registered: 2006-02-09
Posts: 534

Re: latest libgphoto2 - problem with canon camera

hey,

is something wrong with the updates?
I keep getting new apps then an older version pops up as a update. For instance, I updated wine-0.9.12 last week and today, the update is wine-0.9.11-1.
same with libgphoto2. I've updated to libgphoto2-2.1.99 and now I see libgphoto2-2.1.6-6 today.

Offline

Board footer

Powered by FluxBB