64characters / Telephone

SIP softphone for Mac
https://www.64characters.com/telephone
GNU General Public License v3.0
1.08k stars 207 forks source link

Bluetooth initialization does not always work #548

Open gnaegi opened 5 years ago

gnaegi commented 5 years ago

I have a jabra headset and I connect using bluetooth. The headset works great, it is visible in the bluetooth selector and it is connected. I configured the bluetooth device in the telephone app as the input and output device.

When I start bluetooth and then the telephone app all works. But after some time, later in the day when I get a call the headset is not propertly intialized. This also happens when I start a call. I can head in the headset that the headset starts to connect (little beep), however it seems to bee too late for telephone app or something. I get not audio and my phone partner neither. The solution then is to quite telephone app, restart and then it works.

It seems to me that I did not have this problem a year ago, it might have been introduced with some bluetooth changes in MacOS 10.14. Is this a known issue? What can I do about it?

AndrzejOlender commented 4 years ago

I have the same problem.

videomike commented 4 years ago

I recently bought a Jabra Evolve 65 and I seem to have the same problems. Also sometimes when I am in longer telephone calls the quality starts degrading until audio becomes uncomprehensible. the first 10 minutes or so always run fine...

mneuhaus commented 4 years ago

Same issue here as well with SoundMAGIC E11BT and Bose SoundLink. Happens on Incoming and Outgoing Calls "randomly". This does not seem to happen with cable Headphones (switched for 2 Days and didn't have any issues). I'm using MacOS 10.14.6 (18G87) and Telephone Version 1.4 (132)

mneuhaus commented 4 years ago

it just happened again, here's a log after closing the Telephone App:

13:12:56.405           pjsua_core.c  .pjsua version 2.7.2 for Darwin-18.7/x86_64 initialized
13:12:56.468            pjsua_acc.c !....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
13:17:51.509            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
13:22:46.549            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
13:27:41.591            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
13:32:36.629            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
13:37:31.678            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
13:42:26.719            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
13:47:21.764            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
13:52:16.804            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
13:57:11.841            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
14:02:06.888            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
14:07:01.928            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
14:11:56.972            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
14:16:52.027            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
14:21:47.071            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
14:26:42.119            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
14:31:37.163            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
14:36:32.210            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
14:41:27.251            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
14:46:22.297            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
14:51:17.344            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
14:56:12.381            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
15:01:07.430            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
15:06:02.481            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
15:10:57.532            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
15:15:52.589            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
15:20:47.639            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
15:25:42.683            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
15:30:37.732            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
15:35:32.775            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
15:40:27.818            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
15:45:22.865            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
15:50:17.917            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
15:55:12.966            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
16:00:08.009            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
16:05:03.054            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
16:09:58.100            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
16:14:53.145            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
16:19:48.186            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
16:24:43.232            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
16:25:20.909  PJSUAOnIncomingCall.m  ..Incoming call for account 0
16:25:23.288     PJSUAOnCallState.m !.......Call 0 state changed to EARLY (180 Ringing)
16:25:35.853     PJSUAOnCallState.m !..........Call 0 is DISCONNECTED [reason = 487 (Request Terminated)]
16:29:38.281            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
16:34:33.329            pjsua_acc.c  ....Marc Neuhaus <sip:xxx@xxx.com>: registration success, status=200 (OK), will re-register in 300 seconds
16:37:10.181     PJSUAOnCallState.m !.......Call 1 state changed to CALLING
16:37:10.882     PJSUAOnCallState.m !.....Call 1 state changed to EARLY (180 Ringing)
16:37:14.582     PJSUAOnCallState.m  .....Call 1 is DISCONNECTED [reason = 487 (Request Terminated)]
mneuhaus commented 4 years ago

@eofster any chance you could take a look at this? telephone is currently barely usable for me, because i've got a 1/3 chance of a not working connection which is really annoying and is starting to look bad with my customers

eofster commented 4 years ago

I started looking into it, but so far I couldn’t find the callbacks in the OS that the app could subscribe to and reload its state accordingly. The callbacks that trigger the change of audio devices list are already there for a long time and I see them working also when a bluetooth audio device disconnects. I assume that the bluetooth audio device disconnect on timeout isn’t recognized by the OS as device going away and no callback about the device list change is fired. So I’m trying to find some other way of detecting this.

mneuhaus commented 4 years ago

thank you, for looking into it! if you need any help testing, logs, etc. just let me know.

kanni commented 4 years ago

I have the same issue with Apple's AirPods (2nd gen)