Closed iblasi closed 5 years ago
You need to update your installation of libgphoto2, then reinstall python-gphoto2. The installation builds python-gphoto2 to use the installed libgphoto2. (See also the README note in reinstalling: https://github.com/jim-easterbrook/python-gphoto2#reinstalling)
@jim-easterbrook I install it and now I have both of them. I did all the steps and it worked! But the second time strangely again raises the same error. However, I restarted the camera and USB connection and I have been able to capture 20 images and still working. So, how can I check the lib that python-gphoto2 is using to be sure that the error won't appear again?
python-gphoto2 uses whatever libgphoto2 is installed on your computer. It does not install or change libgphoto2. The command pkg-config --modversion libgphoto2
will tell you what version of libgphoto2 is installed. (This is the command that the python-gphoto2 installer uses to determine the library version.) Within Python you can use gphoto2.gp_library_version(0)
to get the library version.
Thank you. I checked the commands you've sent me and, yes, everything is correctly linked after forcing the reinstall with sudo pip install -v -U --force-reinstall gphoto2
$ pkg-config --modversion libgphoto2
2.5.20
$ python
>>> import gphoto2 as gp
>>> gp.gp_library_version(0)
['2.5.20', 'all camlibs', 'gcc', 'ltdl', 'EXIF']
I have tested it several times the Canon EOS 4000D, and it haven't failed recognizing the model. Thanks again.
I was checking at libgphoto2 support (link) that the Canon EOS 4000D is available on gphoto2. In fact, I check that the las version 2.5.20 (link) is actually supporting it as it says in the README. After installing this package with pip
sudo pip install -U -v gphoto2
I see that the last version 1.8.5 istalled and at the same time 2.5.17 of gphoto2 and 2.5.19 of libgphoto2 (looking at /usr/local/bin/gphoto2 and /usr/local/lib/libgphoto2 respectively). So I suupose that due to it, as they are not the last versions the initialization of the camera does not recognize the Canon EOS 4000D:Furthermore, it is clear that 4000D model is not supported as when I run
gphoto2 --list-cameras
, that camera does not appear on the list.So, how can I update python-gphoto2 to use 2.5.20 or recongnize Canon EOS 4000D?
Just to add, the USB shows the camera and the PTPCamera has been killed to avoid