linusdm

linusdm

Getting the caller-id through Bluetooth classic or BLE using one of the telephony profiles

I’m trying to figure out if it’s possible to create a nerves system that can act as a Bluetooth peripheral connected to a telephone, and be notified with the caller-id when there is an incoming telephone call.

Both Bluetooth classic and Bluetooth LE have facilities for this requirement. In Bluetooth classic, there is the Handsfree Profile (HFP). In this profile the audio streams and the control portion (accepting, denying, putting on hold) are tightly coupled.
In BLE there is a whole bundle of profiles (TMAS, TBS, CCP, etc.) that can be used to get to a full-fledged handsfree scenario. But you can also use a subset of these profiles, if you’re only interested in the control part and you’re not interested in routing the audio stream to your device. Your smartwatch can accept a call, while the audio gets routed from your phone to a set of earbuds.

This is just to say that there are profiles conveying the caller-id to a bluetooth connected device, both in Bluetooth classic and BLE.
Has anybody successfully integrated one of these telephony profiles on a nerves device before?

I know there is the blue_herron package that hooks into the HCI layer, bypassing BlueZ entirely. But in order to implement the TMAS profile in BLE, the nerves peripheral would need to implement both a GATT server and a GATT client. Currently only the GATT server role is supported (although it seems that the GATT client role is on the roadmap, according to the readme).

Another path to my goal could be to integrate with BlueZ on the nerves device. There was some discussion in this thread on how to integrate with D-Bus. But since the nerves device would need to be reactive to notifications, and set up a GATT server and GATT client, this doesn’t seem like an easy job.
Maybe there are ways to integrate with BlueZ and get the Bluetooth classic HFP profile to work. But I don’t know where to start there either.

I’m not a bluetooth expert by any means. I’m wading through layers and layers of specifications, and it took me a while to even get to this state where I can ask an intelligent question about it. I’m hoping that I’ve overlooked an easy way to achieve this goal. If so, please do share :slight_smile:

Most Liked

linusdm

linusdm

That’s some deeply nested Perl code :smiley: I can probably learn a lot from this for the Bluetooth classic case (HSP/HFP profiles). It’s using BlueZ and its D-Bus interface.

Thanks, I put it on my radar.

Where Next?

Popular in Questions Top

albydarned
Hello all! I am typing this post from my new MacBook Pro with the M1 chip. I’m loving it so far, and will probably use it as my daily dr...
New
skosch
To my knowledge, put_in, Map.update etc. all have the one limitation of not automatically creating intermediate keys when needed (for exa...
New
chrisalley
ExUnit now has describe blocks which is a welcome addition coming from RSpec. In the docs, it states that nested hierarchies of describe ...
New
gshaw
What is the idiomatic way of matching for not nil in Elixir? E.g., First way: defp halt_if_not_signed_in(conn, signed_in_account) when...
New
joeerl
Hello again - after a longish gap I’ve decided I really must dig into Elixir and see what’s been happening here - so I have a few questio...
New
JDanielMartinez
Hi! May someone helps me, please! I have two apps into an umbrella project: the first one is Database, which manages queries, and the se...
New
RisingFromAshes
I’ve read in another post that it may be possible with a router helper - but I couldn’t find an appropriate one, and tbh, I’m still just ...
New
script
If I have a string “1000 cfu/ml” . I want to remove the characters and / and space . So the string is like this "1000" What is the ...
New
vegabook
I’m brand new to Phoenix and I have stripped one of the demo applications to the bone. I just want to get an svg up on the screen. Here i...
New
lanycrost
Hi everyone! I need implement if…else if…else condition from my elixir code, and anymore of this control flow structures not work proper...
New

Other popular topics Top

Patoshizzle
After calling mix ecto.create I get this error: 17:00:32.162 [error] GenServer #PID<0.412.0> terminating ** (Postgrex.Error) FATAL...
New
Fl4m3Ph03n1x
About me? ( if you have nothing better to do than reading about some random guy in the internet :stuck_out_tongue: ) Hello all, this is ...
New
jerry
Good day to you all. I have been struggling to get a query involving like and ilike to work. Can anyone assist me on this, please? pro...
New
belgoros
I’m not a pro in using Regex and can’t figure out why the following behaviour happens, especially if we take into account the difference ...
New
AngeloChecked
What learn first? Rust or Elixir Hi Elixir community! I’m here because i want learn a new language. I’m a junior developer and mainly i ...
New
joeerl
Hello again - after a longish gap I’ve decided I really must dig into Elixir and see what’s been happening here - so I have a few questio...
New
KronicDeth
Elixir plugin for JetBrain’s IntelliJ Platform (including Rubymine) This is a plugin that adds support for Elixir to JetBrains IntelliJ...
289 36352 110
New
rms.mrcs
Hi, I need to transform a list of numbers into a map where the keys are the indexes and the values are the original values of the list. ...
New
Brian
What is the proper way to load a module from a file in to IEX? In the python world, doing something like this pretty standard: from ....
New
svb
Hi! Currently I want to submit a form by pressing the Enter key. However, since my input field is of type “textarea” this is just adds a...
New

Latest on Elixir Forum

We're in Beta

About us Mission Statement