MCPcopy Create free account
hub / github.com/deviceplug/btleplug / notifications

Method notifications

src/bluez/peripheral.rs:276–283  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

274 }
275
276 async fn notifications(&self) -> Result<Pin<Box<dyn Stream<Item = ValueNotification> + Send>>> {
277 let device_id = self.device.clone();
278 let events = self.session.device_event_stream(&device_id).await?;
279 let services = self.services.clone();
280 Ok(Box::pin(events.filter_map(move |event| {
281 ready(value_notification(event, &device_id, services.clone()))
282 })))
283 }
284
285 async fn read_rssi(&self) -> Result<i16> {
286 let device_info = self.device_info().await?;

Calls 1

value_notificationFunction · 0.85