ptp2: work around an apparent firmware bug in the R5m2 causing it to hang

This commit is contained in:
axxel
2024-09-30 21:27:12 +02:00
committed by Marcus Meissner
parent 56885c02c8
commit 9e9b149ddc

View File

@@ -4829,6 +4829,11 @@ ptp_operation_issupported(PTPParams* params, uint16_t operation)
{
uint32_t i=0;
/* The R5m2 fails to send a PTP response packet after the data packet of the GetDeviceInfoEx.
* This seems to be firmware bug present in version 1.0.0 and 1.0.1. See #1028. */
if (operation == PTP_OC_CANON_EOS_GetDeviceInfoEx && !strcmp(params->deviceinfo.Model,"Canon EOS R5m2"))
return 0;
for (;i<params->deviceinfo.OperationsSupported_len;i++) {
if (params->deviceinfo.OperationsSupported[i]==operation)
return 1;