BLE application

Posted on
  • Hi,
    I posted a conversation a few months ago about it. I'm trying again to establish a BLE communication between my smartphone (with a custom app installed) and my bangle.
    My problem is that I have experience connecting with sensors that streaming data automatically, like BLE pulse oximeter, HR band, and so on. So in such cases, I had to make my smartphone central (so it starts communication) and Gatt client because it receives data from sensors.
    This time is kinda different because the bangle needs to be programmed as a peripheral GATT server and I can't do that, or in other words, it does not work until now in the way I did it.
    If someone has some suggestions/tips I'm glad to hear them.

  • This time is kinda different because the bangle needs to be programmed as a peripheral GATT server and I can't do that

    Can you explain why it needs to be server?
    And BTW bangle can be both central and peripheral, even concurrently.

    Also on which side you see the problem of "I can't do that" - phone or Bangle?

  • Because I want to start a connection on my app scanning for devices and connecting with bangle (so the app is central and watch peripheral), after that bangle starts to stream sensor data, like GPS, HR to my app which saves them locally with SQLite.
    The app side is fine, I have problems with the bangle side because I can connect from the app (i can see it thanks to the BLE widget, but when I want to see services or characteristics I catch an error in my app).
    But having no experience in a situation like that I can't understand what is the problem

  • Oh, OK, sorry, was confused by your comment 'This time is kinda different '. Because there is nothing different when compared to your previous attempts with BLE pulse oximeter, HR band. In all cases phone is central and bangle, oximeter, hr band is peripheral (?) Was thinking you want to do it the other way as the terminology can be confusing.

    So you simply try connect to bangle like it would be any other device before and it fails for you.
    It can be because any other device is connected to it already (espruino ide, gadgetbridge) or you don't have it connectable as per https://www.espruino.com/Bangle.js+Devel­opment

  • It is different because with these sensors I had to program only the client-side, so my app side. BLE sensors stream data independently, in the past project I used to use Light Blue, to understand what the sensor sends, then I used to program my app side in order to receive data.
    I said it's different because this time I have also to program the sensor side (bangle in this case), and I think I'm missing something like setting services or connecting.

  • The app side is fine, I have problems with the bangle side because I can connect from the app (i can see it thanks to the BLE widget, but when I want to see services or characteristics I catch an error in my app).

    Oh so you think it does connect fine but you have exception in the mobile app (android?) and you think problem is on bangle side. Can you connect to bangle from Nordic nrfConnect https://www.nordicsemi.com/Software-and-­tools/Development-Tools/nRF-Connect-for-­mobile and see the characteristics there?

  • O this test is a good idea, I didn't about that, I try and update you.

    Thank you very much.

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

BLE application

Posted by Avatar for valap95 @valap95

Actions