SeanXu1984 / BleGattCharacteristicNotificationSample

A sample APP demonstrates how to advertise a characteristic from BLE Peripheral side and how to subscribe the characteristic from BLE Central side so the BLE Central side will get a notification whenever the characteristic gets changed from the Peripheral side. (BLE, Gatt, BLE Central, BLE Peripheral)
0 stars 0 forks source link

Subscribe notification #1

Open enes-sakut opened 7 years ago

enes-sakut commented 7 years ago

How can I send notification android phone to BLE device using my spesific service UUID?

SeanXu1984 commented 7 years ago

I don't quite get your question. Do you want to send data from Android phone to a BLE device? You can get some basic ideas on how BLE works from the following Apple doc Core BLE doc "There are two major players involved in all Bluetooth low energy communication: the central and the peripheral. Based on a somewhat traditional client-server architecture, a peripheral typically has data that is needed by other devices. A central typically uses the information served up by peripherals to accomplish some particular task. As Figure 1-1 shows, for example, a heart rate monitor may have useful information that your Mac or iOS app may need in order to display the user’s heart rate in a user-friendly way."

"Sometimes it makes sense to write the value of a characteristic. For example, if your app interacts with a Bluetooth low energy digital thermostat, you may want to provide the thermostat with a value at which to set the room’s temperature."

enes-sakut commented 7 years ago

Thank you I created GATT server on my android application and add characteristics,descriptors and onCharacteristicReadRequest methods , but my BLE DEVICE couldn't read anything.Do you have any idea why?

SeanXu1984 commented 6 years ago

When you perform a ble gatt scan from BLE central, were you able to discover the service in the onServicesDiscovered method implemented in gatt call back?