Connecting directly to a specific BLE Device

Hi guys,

Stepped myself through Jim's ConnectIQ BLE example which has been very helpful. I'm can read and write to and from my own hardware now, but onto the next thing.

Question
If I have multiple BLE devices in range, that are all advertising the same characteristic, is there a way I can specifically set which device I want to connect to via mac or some other method?

Cheers,
Matt

  • I forget if that was mentioned in the breakout when this was announced, but I know I learned  it pretty quickly

    In cases where I can control both ends, instead of using just one characteristic to get the data, I'll use two or more.  For example, In addition to the actual data, I wanted to return a string that IDs the specific sensor (a string up to 12 bytes long).  So I use a second characteristic for that.

  • I found the sources for that presentation after some searching here on GitHub: NordicThingy52. It features the most elaborate software design I’ve seen in this context, with multiple classes handling different aspects of the CIQ BLE functionality.
  • With a quick look at the github stuff, that looks to be about the same as one of the Nordicthingy52 samples in the SDK.  There is also the coin collector that plays a sound on the Thingy52 every 2 seconds from a data field.

    When this was announced at the Summit, there was a new SDK that went with the new feature and it had the sample app.  I started looking at the code, and then wrote my own for the Thingy52 that was simpler and more in my style. but there are a couple of things I used from the SDK sample when I wrote BleScan, as well as my apps that work with the Raspberry pi devices and other sensors

    As I had a Thingy52 and the HW needed in the sim, it made the SDK sample much easier to understand, as I could add things like println calls..  That's partly of why I've been talking about you getting a Thingy52 as there is sample code that was known to work with it.

  • Re MTU: at least 5 years ago, a treadmill was sending 150 bytes, and the watch was truncating them to 20 bytes. But at least the connection was possible. See MTU discussion

    And in the presentation, they were saying that pairing and bonding were not an option, which has also changed today. So maybe unencrypted connections are no longer supported?

  • I have an IQ app in the store which connects to a sensor which only supports unencrypted connection. Edge 1050 shows, since latest update, a warning which the user has to commit, before the connection is made.

  • I use the exact same code with the 8.0.0 beta SDK, including on the System8PreviewDevics and real devices with System 8 as I've used for years.  No bonding used.