All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrejs Hanins <andrejs.hanins@ubnt.com>
To: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
Cc: "linux-bluetooth@vger.kernel.org" <linux-bluetooth@vger.kernel.org>
Subject: Re: Notifications and CCC descriptor handling for Gatt server
Date: Wed, 12 Aug 2015 09:16:01 +0300	[thread overview]
Message-ID: <55CAE4A1.5030403@ubnt.com> (raw)
In-Reply-To: <CABBYNZK5y4Kt+NaJ7cm4rhJE8dMyUEJo6ca5iFyrnocviL_dEg@mail.gmail.com>

Hi,

On 08/09/2015 06:13 PM, Luiz Augusto von Dentz wrote:
> Hi Andrejs,
> 
> On Fri, Aug 7, 2015 at 12:31 AM, Andrejs Hanins <andrejs.hanins@ubnt.com> wrote:
>> Hi,
>>
>>         I have a Gatt server over D-Bus with "notify" characteristic exported and I listen to Start/StopNotify methods. But I can't get my head around the logic of Start/StopNotify methods in case of multiple Gatt clients connecting to the service (not in the same time, of course):
>>         1. Client A connects and enables notifications, StartNotify is called - this is fine.
>>         2. Client B connects and enables notifications, then StartNotify is called again - is it expected? Does it mean notifications state is per-client and external Gatt server needs to know the currently connected client and associate some state with it?
> 
> This is probably a bug, bluetoothd shall only call StartNotification
> once, it shall also call StopNotification if there no client
> connected.
So, should I create a bug report?
> 
>>         3. Client A connects again and disables notifications, StopNotify is not called. This is strange and goes against the logic in item 2.
> 
> It shall only call StopNotify if it is the last client, otherwise this is ok.
> 
>>         4. Client B connects and disables notifications, StopNotify is called.
> 
> That is probably fine, it both StartNotify and StopNotify shall only
> be called once.
> 
>>         So, how is it supposed to work? Maybe there is a bug somewhere?
>>         BlueZ 5.32 used.
>>
>> BR, Andrey
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 
> 
> 

      reply	other threads:[~2015-08-12  6:16 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-06 21:31 Notifications and CCC descriptor handling for Gatt server Andrejs Hanins
2015-08-09 15:13 ` Luiz Augusto von Dentz
2015-08-12  6:16   ` Andrejs Hanins [this message]

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=55CAE4A1.5030403@ubnt.com \
    --to=andrejs.hanins@ubnt.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.