On Wed, Oct 05, 2016 at 05:07:00PM -0700, Mike Ryan wrote: > On Thu, Oct 06, 2016 at 02:00:25AM +0200, Kevin Townsend wrote: > > I remember some discussions previously about unsolicited notifies > > and whether this was or wasn't supported in the BLE spec > > My reading of the spec suggests that it is not legal. Referring to > Client Characteristic Configuration on PDF page 2228 of Core v4.2 (Vol. > 3 Part G Sec 3.3.3.3): > > > The Client Characteristic Configuration descriptor value shall be set > > to the default value at each connection with non-bonded devices. > > Later in the same section: > > > The default value for the Client Characteristic Configuration > > descriptor value shall be 0x0000. > > This suggests that the value for notifications will be 0. A value of 1 > signifies "the Characteristic Value shall be notified". It's safe to > assume that a value of 0 therefore means that the value shall not be > notified.
I think you're right about that - a CCCD should not be set to one unless the peer writes to it. What I'm not so sure about is whether it is prohibited to send a notification to an unsubscribed peer. I didn't see any language in the spec indicating that this is illegal. The ability to send unsolicited notifications is useful, and I don't see a reason why it shouldn't be allowed. That said, I believe iOS will drop incoming notifications for a characteristic that doesn't have a CCCD. I don't believe android has this limitation. If iOS requires the characteristic to be subscribable, then I think we need to comply. Thanks, Chris