I converted my RPI into a hub for my room(it rests upon the wall and shows the current time, weather, what Music is playing(shairport-sync), and a spot for notifications.
From my personal experience, I've always noticed that bluetooth devices -- like smart watches and cars can read notifications. So I had an idea to connect my RPI to my iPhone and read the notifications coming from my phone. However though, I've made very little head away in implementing this.
So far, I have set up a separate machine that off hands all of the bluetooth stuff so the RPI has room to breathe. Other than that though I cannot figure out how to connect to iOS, subscribe to notifications, and retrieve them. I have looked into this topic extensively and have found many articles talking about ASCN, subscribing to certain Apple Services, using a MAP profile, and a whole lot of stuff about GATT Servers but these articles lack practical steps or any headers on where to get started.
I've been using various python libraries(pybluez, bleak, etc) in conjugation with BlueZ to try to connect and retrieve iOS Notifications using bluetooth. Many of the Articles and posts about this topic usually involves a BLE device communicating with an app in iOS which isn't what I need.
TLDR; : I need help/a point in the right direction to pairing and subscribing to bluetooth iOS notifications using Python.
-
1You want to connect to the ANCS service on the phone.Paulw11– Paulw112022年07月15日 04:26:48 +00:00Commented Jul 15, 2022 at 4:26
-
It's not my fault that you want to do something that no one else seems to have provided guides on. There seem to be few examples of using Bluez as a central. I found this which is C, but it may give you some pointers. You need your code to discover a peripheral advertising the ANCS service, connect to it and then subscribe to the ANCS notification characteristic.Paulw11– Paulw112022年07月31日 22:04:31 +00:00Commented Jul 31, 2022 at 22:04