1

I am working on a BLE interface to setup wifi on a device. I need to send a list of available networks back from the device. Should I have 10 characteristics (one for each available SSID) or just one characteristic which I send 10 notifies on.

What is the risk of using one option vs. the other? How reliable are the notifications of the values? I assume repeated notifications on one characteristic are likely as reliable as a single notification on multiple characteristics?

jr.
  • 4,503
  • 7
  • 44
  • 62
  • All I can say is don't have 10 characteristics. Notifications work fine on all platforms I've seen. – Emil Apr 26 '20 at 01:47
  • My testing has shown that having a single characteristic firing notifications XX times seems to work just fine, so I guess its OK.. BLE Is kinda fun. – jr. Apr 26 '20 at 01:48

1 Answers1

0

My recommendation is to use one characteristic for this purpose. It's not really about the risk as option 1 and option 2 should work fine, but it is more about the architecture of your code; i.e. If a new network is found, it is relatively easier and more logical to send data on one characteristic than associate the found SSID with a new characteristic. Moreover, you would have unutilized characteristics if you end up finding less than 10 SSIDs. Finally, if you wanted to expand the functionality of your device, you can than start using other characteristics for new features which will make things more modular for the remote device.

As both you and Emil have said, having a single characteristic firing notifications should not be an issue on any platform.

Youssif Saeed
  • 11,789
  • 4
  • 44
  • 72