From: Bastien Nocera <hadess@hadess.net>
To: "Frédéric Danis" <frederic.danis@collabora.com>,
"Luiz Augusto von Dentz" <luiz.dentz@gmail.com>
Cc: linux-bluetooth@vger.kernel.org
Subject: Re: [PATCH BlueZ 2/3] doc/device: Add Disconnected signal
Date: Tue, 20 May 2025 12:22:06 +0200 [thread overview]
Message-ID: <a449a563d74a2df27dd6f0c95365ea4e97053b9e.camel@hadess.net> (raw)
In-Reply-To: <6acf1b43-77f6-4484-8af6-5fe492e6ec6e@collabora.com>
On Tue, 2025-05-20 at 11:32 +0200, Frédéric Danis wrote:
> Hi Bastien,
>
> On 19/05/2025 21:22, Bastien Nocera wrote:
> > On Mon, 2025-05-19 at 12:44 -0400, Luiz Augusto von Dentz wrote:
> > > Hi Frédéric,
> > >
> > > On Mon, May 19, 2025 at 12:18 PM Frédéric Danis
> > > <frederic.danis@collabora.com> wrote:
> > > > ---
> > > > doc/org.bluez.Device.rst | 17 +++++++++++++++++
> > > > 1 file changed, 17 insertions(+)
> > > >
> > > > diff --git a/doc/org.bluez.Device.rst
> > > > b/doc/org.bluez.Device.rst
> > > > index 80501eddd..6229f95ad 100644
> > > > --- a/doc/org.bluez.Device.rst
> > > > +++ b/doc/org.bluez.Device.rst
> > > > @@ -155,6 +155,23 @@ array{array{byte}} GetServiceRecords()
> > > > [experimental]
> > > > :org.bluez.Error.NotConnected:
> > > > :org.bluez.Error.DoesNotExist:
> > > >
> > > > +Signals
> > > > +-------
> > > > +
> > > > +void Disconnected(string reason)
> > > > +````````````````````````````````
> > > > +
> > > > + This signal is launched when a device is disconnected
> > > > with
> > > > the reason of
> > > > + the disconnection.
> > > > +
> > > > + Possible reasons:
> > > > +
> > > > + :disconnection-unknown:
> > > > + :disconnection-timeout:
> > > > + :disconnection-local-host:
> > > > + :disconnection-remote:
> > > > + :disconnection-local-suspend:
> > > Perhaps it would be better to use to the actual HCI code instead
> > > of
> > > converting it to string, since I suspect application using this
> > > signal
> > > may want to recover the actual error to do some sort of
> > > reconnecting
> > > policy, etc, or having them both in case the client just wants to
> > > print it.
> > If there are applications using those signals (I'm guessing,
> > Bluetooth
> > settings apps), whatever the format of the error, could we have an
> > expected behaviour associated with individual error types?
>
> This could be used by client apps like Bluetooth setting to try to
> reconnect to the device in case of timeout or unknown disconnection,
> or to try to connect to another device depending on internal policy.
I meant having that information in the docs :)
Cheers
next prev parent reply other threads:[~2025-05-20 10:22 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-19 16:14 [PATCH BlueZ 0/3] Propagate disconnection reason Frédéric Danis
2025-05-19 16:14 ` [PATCH BlueZ 1/3] src/device: Add Disconnected signal to propagate " Frédéric Danis
2025-05-19 17:56 ` Propagate " bluez.test.bot
2025-05-19 16:14 ` [PATCH BlueZ 2/3] doc/device: Add Disconnected signal Frédéric Danis
2025-05-19 16:44 ` Luiz Augusto von Dentz
2025-05-19 19:22 ` Bastien Nocera
2025-05-20 9:32 ` Frédéric Danis
2025-05-20 10:22 ` Bastien Nocera [this message]
2025-05-20 9:26 ` Frédéric Danis
2025-05-19 16:14 ` [PATCH BlueZ 3/3] client: Display disconnection reason Frédéric Danis
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a449a563d74a2df27dd6f0c95365ea4e97053b9e.camel@hadess.net \
--to=hadess@hadess.net \
--cc=frederic.danis@collabora.com \
--cc=linux-bluetooth@vger.kernel.org \
--cc=luiz.dentz@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox