Bluetooth data update notifications do not start

I am having some problems reading data from a bluetooth peripheral device. We have a bluetooth device with the following gatt details.

<service uuid="service id" advertise="true">
    <description>XXXX service</description>
    <characteristic uuid="characteristic id" id="xgatt_data">
        <description>Data</description>
        <properties write="true" indicate="true" />
        <value variable_length="true" length="20" type="user" />
    </characteristic>
</service>

What i do is

  • Search for a peripheral device that has a "service identifier"
  • Connect to a peripheral device that was once found and maintains a strong link to it.
  • After connecting the delegate settings and searching for all services, it provides
  • start all services and scan the characteristics as soon as we discover the services
  • after I found the desired characteristic, I activate the notification
  • When I click a button, I write data on the characteristics

. () . , . , . iOS , , . ?

+4
2

. . BLE "" "".

0

- . , , , , , ( ).

: xgatt_data "Write", . "", , .

, (UUID 00002901-..) xgatt_data. CCCD " + ", / ( , - ).

, , , MTU , , . , , DLE, MTU .

+2

Source: https://habr.com/ru/post/1679896/


All Articles