Re: [Sony Alpha7] no work

Jeroen Lichtenauer <[email protected]> Fri, 5 Apr 2024 17:36:49 +0200
Newsgroups gmane.comp.multimedia.gphoto.devel
Message-ID <CAM_--AybEauAisGvUeRyT7nHZUUYwNNzYf2VtMsJUjmSddk+fQ@mail.gmail.com>
--===============7064439444321474252==
Content-Type: multipart/alternative; boundary="000000000000b0243406155b3bd9"

--000000000000b0243406155b3bd9
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

Hi Marcus,

Thanks for the tips on handling the different data types. Just adding a
second line in the submenu table didn't work. It would still try to get the
datatype of the first line that it encounters.
So I added separate submenu tables for the ILCE-7SM3 and device specific
references in the menus:

static struct submenu sony_7sm3_camera_settings[] =3D {
{ N_("Priority Mode"), "prioritymode", PTP_DPC_SONY_PriorityMode,
 PTP_VENDOR_SONY, PTP_DTC_UINT8, _get_Sony_PriorityMode_u8,
_put_Sony_PriorityMode_u8 },
{ 0,0,0,0,0,0,0 },
};

static struct submenu sony_7sm3_capture_settings[] =3D {
{ N_("Exposure Program"),               "expprogram",
PTP_DPC_ExposureProgramMode,            0,                  PTP_DTC_UINT32,
_get_ExposureProgram32,               _put_ExposureProgram32 },
{ N_("Still Capture Mode"),             "capturemode",
 PTP_DPC_StillCaptureMode,               0,
 PTP_DTC_UINT32, _get_CaptureMode32,               _put_CaptureMode32 },
{ 0,0,0,0,0,0,0 },
};

static struct menu menus[] =3D {
    ...
    { N_("Camera Settings"),            "settings",         0x054c, 0x0d18,
sony_7sm3_camera_settings,      NULL,   NULL }, /* A7S-III */
    ...
    { N_("Capture Settings"),           "capturesettings",  0x054c, 0x0d18,
sony_7sm3_capture_settings,     NULL,   NULL }, /* A7S-III */
    ...
}

Something else that doesn't work is changing the ISO, shutterspeed and
f-number settings. On the Sony A7-III changing those settings worked
incremental, step-by-step. It also worked slowly like that with the Imaging
Edge Desktop application.
On the contrary, with the Sony A7S-III, the ISO, shutterspeed and f-number
are changed instantaneously by Imaging Edge. So probably a different
settings-change method needs to be used, such as the direct method.

To try and search for the missing unreported properties and actions
(autofocus, capture, focusmagnify, etc.) I found that in the end
of _ptp_sony_getalldevicepropdesc, the size left is zero. So, clearly, it
didn't end on a decoding error. Just nothing left to decode. Could it be
that there's another way to get more data than with the
current PTP_DP_GETDATA query?

Unfortunately, I have run out of time to work on this and will not have
access to this camera model anymore, so I won't be able to check any future
fixes.
Would be great if support for the A7S-III will be completed in the future.
As well as for the Sony A7-IV, which was also not fully functional, the
last time I checked.

Kind regards, Jeroen

On Fri, Apr 5, 2024 at 10:01=E2=80=AFAM Marcus Meissner <[email protected]=
.de>
wrote:

> Hi,
>
> In theory you should be able to add the 32bit variant as a secondary
> choice.
>
> The config code should skip the 16 bit variant if you have 32bit type,
> and then select the 32bit type.
>
> So copy the table and name it modes32 and just add the new line.
>
>
> There is "by usb id" table based driven code there (look for nikon ones),
> but I think just adding a different line with the different data type
> should
> work more transparently.
>
> > Unfortunately, still the operations/properties below are missing. I gue=
ss
> > there might be some more binary coding differences for operations as
> well.
> > Still some more work to do...
> >
> > Autofocus(0xd2c1): error 2002 on query.
> > Capture(0xd2c2): error 2002 on query.
> > Property 0xd2c3: error 2002 on query.
> > Property 0xd2c4: error 2002 on query.
>
> If the camera does not report them we can't really get to them.
>
> 0xd2c are also kind of write-only for instance.
>
> Ciao, Marcus
>

--000000000000b0243406155b3bd9
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div>Hi Marcus,</div><div><br></div><div>Thanks for the ti=
ps on handling the different data types. Just adding a second line in the s=
ubmenu table didn&#39;t work. It would still try to get the datatype of the=
 first line that it encounters.</div><div>So I added separate submenu table=
s for the ILCE-7SM3 and device specific references in the menus:</div><div>=
<br>static struct submenu sony_7sm3_camera_settings[] =3D {<br>	{ N_(&quot;=
Priority Mode&quot;),		&quot;prioritymode&quot;,		PTP_DPC_SONY_PriorityMode=
, =C2=A0	 =C2=A0 =C2=A0PTP_VENDOR_SONY,	PTP_DTC_UINT8, 	_get_Sony_PriorityM=
ode_u8, =C2=A0 =C2=A0 	_put_Sony_PriorityMode_u8 },<br>	{ 0,0,0,0,0,0,0 },<=
br>};<br><br>static struct submenu sony_7sm3_capture_settings[] =3D {<br>	{=
 N_(&quot;Exposure Program&quot;), =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=
=A0 =C2=A0 &quot;expprogram&quot;, =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=
=A0 =C2=A0 PTP_DPC_ExposureProgramMode, =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =
=C2=A00, =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0PTP_=
DTC_UINT32, _get_ExposureProgram32, =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=
=A0 =C2=A0 _put_ExposureProgram32 },<br>	{ N_(&quot;Still Capture Mode&quot=
;), =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 &quot;capturemode&quot;, =C2=
=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0PTP_DPC_StillCaptureMode, =C2=
=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 0, =C2=A0 =C2=A0 =C2=A0 =C2=
=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0PTP_DTC_UINT32, _get_CaptureMode32, =
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 _put_CaptureMode32 },<br>	=
{ 0,0,0,0,0,0,0 },<br>};<br></div><div><br></div><div>static struct menu me=
nus[] =3D {<br>=C2=A0 =C2=A0 ...<br>=C2=A0 =C2=A0 { N_(&quot;Camera Setting=
s&quot;), =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0&quot;settings&quot;, =
=C2=A0 =C2=A0 =C2=A0 =C2=A0 0x054c, 0x0d18, sony_7sm3_camera_settings, =C2=
=A0 =C2=A0 =C2=A0NULL, =C2=A0 NULL }, /* A7S-III */<br></div><div>=C2=A0 =
=C2=A0 ...</div><div>=C2=A0 =C2=A0 { N_(&quot;Capture Settings&quot;), =C2=
=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 &quot;capturesettings&quot;, =C2=A00x054c, =
0x0d18, sony_7sm3_capture_settings, =C2=A0 =C2=A0 NULL, =C2=A0 NULL },	/* A=
7S-III */<br></div><div>=C2=A0 =C2=A0 ...</div><div>}</div><div><br></div><=
div>Something else that doesn&#39;t work is changing the ISO,=C2=A0shutters=
peed=C2=A0and f-number settings. On the Sony A7-III changing those settings=
 worked incremental, step-by-step. It also worked slowly like that with the=
 Imaging Edge Desktop application.=C2=A0</div><div>On the contrary, with th=
e Sony A7S-III, the ISO, shutterspeed=C2=A0and f-number are changed instant=
aneously by Imaging Edge. So probably a different settings-change method=C2=
=A0needs to be used,=C2=A0such as the direct method.</div><div><br></div><d=
iv>To try and search=C2=A0for the missing unreported properties and actions=
 (autofocus, capture, focusmagnify, etc.) I found that in the end of=C2=A0_=
ptp_sony_getalldevicepropdesc, the=C2=A0size left is zero. So, clearly, it =
didn&#39;t end on a decoding error. Just nothing left to decode. Could it b=
e that there&#39;s another way to get more data than with the current=C2=A0=
PTP_DP_GETDATA query?</div><div><br></div><div>Unfortunately, I have run ou=
t of time to work on this and will not have access to=C2=A0this camera mode=
l anymore,=C2=A0so I won&#39;t be able to check any future fixes.=C2=A0</di=
v><div>Would be great if support for the=C2=A0A7S-III will be completed in =
the future. As well as for the Sony A7-IV, which was also not fully functio=
nal, the last time I checked.=C2=A0</div><div><br></div><div>Kind regards, =
Jeroen</div><br><div class=3D"gmail_quote"><div dir=3D"ltr" class=3D"gmail_=
attr">On Fri, Apr 5, 2024 at 10:01=E2=80=AFAM Marcus Meissner &lt;<a href=
=3D"mailto:[email protected]">[email protected]</a>&gt; wrote:<br><=
/div><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;bo=
rder-left:1px solid rgb(204,204,204);padding-left:1ex">Hi,<br>
<br>
In theory you should be able to add the 32bit variant as a secondary choice=
.<br>
<br>
The config code should skip the 16 bit variant if you have 32bit type,<br>
and then select the 32bit type.<br>
<br>
So copy the table and name it modes32 and just add the new line.<br>
<br>
<br>
There is &quot;by usb id&quot; table based driven code there (look for niko=
n ones),<br>
but I think just adding a different line with the different data type shoul=
d<br>
work more transparently.<br>
<br>
&gt; Unfortunately, still the operations/properties below are missing. I gu=
ess<br>
&gt; there might be some more binary coding differences for operations as w=
ell.<br>
&gt; Still some more work to do...<br>
&gt; <br>
&gt; Autofocus(0xd2c1): error 2002 on query.<br>
&gt; Capture(0xd2c2): error 2002 on query.<br>
&gt; Property 0xd2c3: error 2002 on query.<br>
&gt; Property 0xd2c4: error 2002 on query.<br>
<br>
If the camera does not report them we can&#39;t really get to them.<br>
<br>
0xd2c are also kind of write-only for instance.<br>
<br>
Ciao, Marcus<br>
</blockquote></div></div>

--000000000000b0243406155b3bd9--


--===============7064439444321474252==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline


--===============7064439444321474252==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Gphoto-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gphoto-devel

--===============7064439444321474252==--