Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Leica Q3 #601

Closed
trevorski opened this issue Sep 10, 2023 · 9 comments
Closed

Leica Q3 #601

trevorski opened this issue Sep 10, 2023 · 9 comments
Assignees
Labels
Leica for issues with Leica cameras

Comments

@trevorski
Copy link

trevorski commented Sep 10, 2023

Name of the camera

Leica Q3

USB IDs

(serial number blanked out)

% sudo lsusb | grep -i leica
Bus 000 Device 002: ID 1a98:2376 Leica Camera AG LEICA Q3  Serial: 000000000XXXXXXX
Bus 000 Device 000: ID 1a98:2376 Leica Camera AG USB 3.1 Bus

camera summary output

(serial number blanked out)

summary.txt

camera configuration output

list-all-config.txt

test capture

test if capture perhaps already works:

gphoto2 --trigger-capture works gphoto2 --capture-image-and-download takes a photo but fails to move past that and gphoto2 --capture-preview fails with *** Error (-1: 'Unspecified error') ***.

Let me know if you'd like debug logs, USB traffic captured or any more info.

Thanks!

@msmeissn
Copy link
Contributor

can you get debug output from the failed capture+download?
and also from the capture preview?

@msmeissn msmeissn self-assigned this Sep 16, 2023
@trevorski
Copy link
Author

OK, I've attached the debug output for both failed commands. One thing probably work noting is that the capture preview fails and seems to terminate the PTP session as the camera resumes its untethered state after the command returns.

Thanks a bunch & I'm excited for gphoto2 to support the Q3!

capture-preview-failure.txt
capture-and-download-failure.txt

@msmeissn
Copy link
Contributor

There is some weirdness, that the session is reported already open which led to the error.

0.059354 ptp_usb_getresp [usb.c:516] (0): PTP_OC 0x1015 receiving resp failed: PTP Session Not Open (0x2003)
0.059360 camera_capture_preview library.c:3988: 'ptp_getdevicepropvalue (params, PTP_DPC_SupportedStreams, &propval, PTP_DTC_UINT32)' failed: PTP Sessio
n Not Open (0x2003)

Currently the code does not seem to take the Leica specific paths as it did not know the USB id.

I have now added the USB id to libgphoto2, so one thing you can try is to update libgphoto2 to current GIT master, where I added the USB id?

@trevorski
Copy link
Author

OK, I built gphoto2 against libgphoto2 built from master and it still seems to have the same (failing) behavior. Logs attached.

Thanks!

capture-image-and-download-logfile.txt
capture-preview-logfile.txt

msmeissn added a commit to gphoto/libgphoto2 that referenced this issue Sep 30, 2023
@msmeissn
Copy link
Contributor

i added another fix, can you pull , rebuild and retest?

@trevorski
Copy link
Author

gphoto2 --capture-preview works now! gphoto2 --capture-image-and-download still seems to fail/hang and I've attached the logs. Thanks!

capture-image-and-download.txt

@msmeissn
Copy link
Contributor

msmeissn commented Oct 7, 2023

So it waits for the "Capture COmplete" event, which does not arrive.

  1. can you try if it works better if you do not use Dual JPG+DNG capture? e.g. single image either JPG or DNG?

  2. can you change the line in camlibs/ptp2/library.c:

     {"Leica:Q3",                            0x1a98, 0x2376, PTP_CAP|PTP_CAP_PREVIEW},
    

to
{"Leica:Q3", 0x1a98, 0x2376, PTP_CAP|PTP_CAP_PREVIEW|PTP_NO_CAPTURE_COMPLETE},
and rebuild, this should also fix it.

@msmeissn msmeissn added the Leica for issues with Leica cameras label Oct 9, 2023
@trevorski
Copy link
Author

  1. My previous build was lost so I wasn't able to figure this out, but...

  2. gphoto2 --capture-image-and-download now works with both dual DNG+JPG capture!

@msmeissn
Copy link
Contributor

msmeissn commented Nov 8, 2023

very good! :)
I think we solved the issues :)

@msmeissn msmeissn closed this as completed Nov 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Leica for issues with Leica cameras
Projects
None yet
Development

No branches or pull requests

2 participants