Re: [Bluez PATCH v1 1/2] doc/media-api: Add Press method for MediaPlayer1

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Archie,

On Mon, Aug 31, 2020 at 10:33 PM Archie Pusaka <apusaka@xxxxxxxxxx> wrote:
>
> Hi Luiz,
>
> On Tue, 1 Sep 2020 at 13:20, Luiz Augusto von Dentz
> <luiz.dentz@xxxxxxxxx> wrote:
> >
> > Hi Archie,
> >
> > On Mon, Aug 31, 2020 at 8:19 PM Archie Pusaka <apusaka@xxxxxxxxxx> wrote:
> > >
> > > Hi Luiz,
> > >
> > > The reason we introduced this method is because we need to send some
> > > of AVRCP category 2 passthroughs in order to be able to qualify the
> > > AVRCP absolute volume control as an audio source, despite we don't
> > > actually plan to send any passthrough in the practice.
> >
> > I wonder what those are, are they volume up/down?
> Yes, volume up/down and mute are the ones that are unique to category
> 2, but there are also some other buttons which are included in
> category 2 as well but not unique to it, for example button 0 - 9,
> help, and power.

Weird, there are dedicated commands for setting absolut volume, not
sure why one would use volume up/down to qualify? Or is that testing
any button that belongs to category 2? Anyway it would be nice to know
what test that is and what is the expected behavior the test case
expects from us.

>
> >
> > > Therefore, which passthrough we send is actually not important (to
> > > us), as long as we can do that to satisfy the requirement.
> > > However, I see that there are over 50 passthroughs across category 1 -
> > > 4, and thought that it would be cumbersome to have a different method
> > > for each key if one day we decided to support them all, hence the
> > > generic method.
> >
> > Yep, but there are button presses so things gets a little more
> > complicated if we need to emulate press/hold/release semantics.
> For now, I don't think having a separate method for each key will make
> it easier if we need to emulate hold and release semantics.
>
> Could we have 3 methods as follows, all have avc_key as a param:
> (a) press. This means BlueZ will auto-release it within a short amount of time
> (b) hold. Bluez wouldn't release it unless it received (c).
> (c) release. Bluez will release the previously held button.
> What do you think?

I'm fine with that, we might have to start the status of each request
though, also the holding should not last longer than 2 seconds if I
recall correctly.

> >
> > > May I have some questions?
> > > (1) Why do you prefer a dedicated method per key?
> > > (2) Let's say I need to add a dedicated method for a single category 2
> > > passthrough key, do you have a key in mind or I can just pick by
> > > myself?
> > >
> > > Thanks,
> > > Archie
> > >
> > >
> > > On Tue, 1 Sep 2020 at 01:16, Luiz Augusto von Dentz
> > > <luiz.dentz@xxxxxxxxx> wrote:
> > > >
> > > > Hi Archie,
> > > >
> > > > On Mon, Aug 31, 2020 at 12:37 AM Archie Pusaka <apusaka@xxxxxxxxxx> wrote:
> > > > >
> > > > > From: Archie Pusaka <apusaka@xxxxxxxxxxxx>
> > > > >
> > > > > This allows us to send any passthrough command.
> > > > >
> > > > > Reviewed-by: Michael Sun <michaelfsun@xxxxxxxxxx>
> > > > > ---
> > > > >
> > > > >  doc/media-api.txt | 8 ++++++++
> > > > >  1 file changed, 8 insertions(+)
> > > > >
> > > > > diff --git a/doc/media-api.txt b/doc/media-api.txt
> > > > > index dabc69936..fe7222eef 100644
> > > > > --- a/doc/media-api.txt
> > > > > +++ b/doc/media-api.txt
> > > > > @@ -199,6 +199,14 @@ Methods            void Play()
> > > > >                         Possible Errors: org.bluez.Error.NotSupported
> > > > >                                          org.bluez.Error.Failed
> > > > >
> > > > > +               void Press(byte avc_key)
> > > > > +
> > > > > +                       Press a specific key to send as passthrough command.
> > > > > +
> > > > > +                       Possible Errors: org.bluez.Error.InvalidArguments
> > > > > +                                        org.bluez.Error.NotSupported
> > > > > +                                        org.bluez.Error.Failed
> > > > > +
> > > > >  Properties     string Equalizer [readwrite]
> > > > >
> > > > >                         Possible values: "off" or "on"
> > > > > --
> > > > > 2.28.0.402.g5ffc5be6b7-goog
> > > >
> > > > For now I would prefer to use dedicated method per key or are there
> > > > many keys you would like to use from the upper layer?
> > > >
> > > >
> > > > --
> > > > Luiz Augusto von Dentz
> >
> >
> >
> > --
> > Luiz Augusto von Dentz
>
> Thanks,
> Archie



-- 
Luiz Augusto von Dentz



[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux