[Home]

Summary:ASTERISK-10389: Poor audio quality and sometimes disconnection after hangup
Reporter:Martin Swaczyna (swatchy)Labels:
Date Opened:2007-09-26 03:18:41Date Closed:2009-04-09 11:46:04
Priority:MajorRegression?No
Status:Closed/CompleteComponents:Addons/chan_mobile
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) crash_31_backtrace.txt
( 1) crash_31_debug.txt
( 2) crash_31_print.txt
( 3) crash_bt.txt
( 4) crash_repeated.txt
( 5) debug1.diff
( 6) hciconfig
( 7) hcidebug
( 8) hcidebug_sip
( 9) lspci
(10) lsusb
(11) mobile.conf
Description:Some information about my system:
OS Ubuntu 7.04
Bluez: 3.9-0ubuntu1
Bluetooth: Internal Bluetooth from Acer C110 Notebook
Asterisk: SVN-trunk-r83834
chan_mobile: Revision 451
Cellphone: Nokia 6230i

These things are working:
1. Notebook and Nokia are paired
2. Outgoing call from iax phone -> asterisk -> pstn works
3. Incoming call not tested
4. Incoming/outgoing SMS are working

The problem:
At the time the pstn phone picks up the call from the cellphone, you can hear the person sitting behind the iax softphone very quiet and with a really poor audio quality. It sounds like a robot is speaking to you.

My tries to solve the problem:
In mobile.conf:
forcemaster set to no and yes
alignmentdetection set to no and yes
Set the iax softphone to gsm and ulaw

Another problem:
Sometimes after hangup the call the connection between asterisk and the cellphone breaks up. I don't know why? See this for more information:







****** ADDITIONAL INFORMATION ******

Asterisk CLI:
   -- Hungup 'IAX2/10-4'
   -- Bluetooth Device Nokia has disconnected, reason (104).
   -- Bluetooth Device Nokia has connected.
   -- Bluetooth Device Nokia initialised and ready.
Comments:By: Martin Swaczyna (swatchy) 2007-09-26 03:39:27

Sorry this was my first entry here and i did't saw that it is possible to attach files after sending this report.

By: Dave Bowerman (dbowerman) 2007-09-26 05:55:58

which iax client are you using?
also, is it possible you could try a sip phone with your setup?

By: Martin Swaczyna (swatchy) 2007-09-27 02:03:09

I used kiax as the softphone on the same machine asterisk is running.

Now I tried it with a eyebeam softphone (sip). But the problem that the bluetooth connection breaks up still appears. I dialed my pstn number and hung up before we were connected. Then asterisk throws out reason "104" disconnects and reconnects again. I added again a dump file (hcidebug_sip) to give you some information.

My tries with eyebeam showed up the same audio problems. But this time you can't hear the other person sitting behind the sip phone even the volume was set to a maximum.

With kind regards,

Martin

By: Dave Bowerman (dbowerman) 2007-09-27 06:08:30

ok, this is the first time ive heard of someone using an embedded bluetooth adapter.
could you post the output of 'hciconfig -a' and lsusb and lspci ?
thanks

By: Martin Swaczyna (swatchy) 2007-09-27 08:33:43

I uploaded the requested files.

I tried chan_mobile with a usb-dongle on another pc. The same problem there as well. The only thing is that I am not sure if hcidump showed SCO packets?!

Does chan_mobile depend on a bluetooth stick with special function like Handsfree Profile?

Martin

By: Josef Liska (phokz) 2007-10-24 16:39:22

I can confirm that the same is happening to me with:
asterisk 1.4.13, chan_mobile r.451 and a sip client (twinkle, sipura)

When I use older version (r.438), there are no disconnects after hangup.

By: Dave Bowerman (dbowerman) 2007-12-23 03:20:49.000-0600

could you test with latest trunk please?

By: Vladimir Latyshev (latysheff) 2007-12-24 07:27:21.000-0600

Disconnection issue remains.
I simply commented out 2 lines, and it worked for me. Older version (r.438) don't have them:

           case MBL_STATE_HANGUP:
               if (strstr(buf, "OK") || strstr(buf, pvt->ciev_call_0)) {
                   //close(pvt->sco_socket);
                   //pvt->sco_socket = -1;
                   pvt->state = MBL_STATE_IDLE;
               }
               break;

By: Josef Liska (phokz) 2007-12-27 03:50:44.000-0600

Hello,
I can confirm that removing two lines suggested by latysheff resolves the disconnect after hangup issue in my test setup:

asterisk stable 1.4.16.2
usb bluetooth stick ID 0a12:0001 Cambridge Silicon Radio, Ltd Bt Dongle (HCI mode)
Nokia 6230i
grandstream sip shone
I had to make some patching to make latest chan_mobile (499) compile with stable asterisk.

I can also confirm that sound quality is good, at least on outgoing calls.
When I try incoming calls with this setup, I get Bluetooth Device nokia has disconnected, reason (104).

I also tried the same hw with asterisk trunk - r.94827

Results:
outgoing calls - disconnection after hangup. When i removed the two lines, it worked ok. Another issue with outgoing calls (probably not connected with chan_mobile, but with asterisk itself) is core dump after sending dtmf from sip to mobile.

incoming calls - the same behavior as with asterisk stable.

My test system is ubuntu 7.04 on i586.



By: Vladimir Latyshev (latysheff) 2007-12-27 04:24:29.000-0600

Yes, DTMF issue exists in my case too. Not core dump but permanent tone regeneration of first (and last :-) ) DTMF digit. If using another channel, not Mobile, there is no problem.
My system is ALTLinux, Asterisk SVN-trunk-r94396

By: Dave Bowerman (dbowerman) 2007-12-27 05:00:15.000-0600

ok, my Nokia 6120c doesnt exhibit this behaviour. ill test it and commit to trunk if no side effects

By: Josef Liska (phokz) 2007-12-27 05:07:21.000-0600

I retested incoming calls with another mobile (N6234) and it is working.

Could you please give me a hint what debug info should I post?

But things are not still ideal.
My machine crashed and I had to switch it off. After boot I started asterisk. When mobile connected to ast. I placed a call to it, answred it on sip side and got no sound at all. When i placed another call, phone didn't pick it up.

After stop now and new asterisk -vvvvvvc it worked.

I also realized that my N6230i has very old firmware - r3.40, current firmware is according to google 3.81. This might be important too.



By: Vladimir Latyshev (latysheff) 2007-12-27 06:08:09.000-0600

I connect to my test asterisk by sip from another asterisk box.
If sip mode set to inband, voice disappears after digit is pressed.
If sip mode set to rfc, tone 'hangs' (regenerating permanently).

But if I comment out (again :)) one string in chan_mobile.c, everithing is ok:

                   ast_dsp_set_features(pvt->dsp, DSP_FEATURE_DTMF_DETECT);
                   //ast_dsp_digitmode(pvt->dsp, DSP_DIGITMODE_DTMF | DSP_DIGITMODE_RELAXDTMF);
                   pvt->adapter = adapter;

A bit annoying thing is long tones (about 1 sec) generated by Asterisk into Mobile channel, but perhaps it is a subject for configuring.



By: Josef Liska (phokz) 2007-12-29 08:12:20.000-0600

Hello, yesterday I managed to drop at local nokia service and had my phone (N6230i) firmware upgraded from 3.40 to 3.89.

I tested it at home on different computer (suse10.2) and it seem to be able to pick up incoming calls without problems.

I'll retest it again (and more deeply) on Ubuntu system on Wednesday.

By: Josef Liska (phokz) 2008-01-03 06:04:39.000-0600

Hello,
I tested my setup again on Ubuntu 7.04 and unfortunately it is not working well.
Outgoing calls are quite good, I got several successfull calls and one problem (Disconnect reason 104). Phone disconnected just before it started dialing.

But with incoming calls I have worse score. I got few successfull calls, but most calls end with Disconnect reason 104 before mobile is picked up by asterisk.

[Jan  3 13:02:59] DEBUG[1664]: chan_mobile.c:1818 do_sco_listen: accept()ed socket.
[Jan  3 13:02:59] DEBUG[1664]: chan_mobile.c:1823 do_sco_listen: Incoming Audio Connection from device 00:16:BC:12:CB:5E MTU is 64
[Jan  3 13:02:59] DEBUG[1664]: chan_mobile.c:1815 do_sco_listen: About to accept() socket.
[Jan  3 13:02:59] DEBUG[1663]: chan_mobile.c:1306 do_monitor_phone: rfcomm_read() (nokia) [RING]
[Jan  3 13:02:59] DEBUG[1663]: chan_mobile.c:1404 do_monitor_phone: Device nokia [RING]
[Jan  3 13:02:59] DEBUG[1663]: chan_mobile.c:1306 do_monitor_phone: rfcomm_read() (nokia) [+CLIP: "+420776026526",145]
   -- Executing [s@incoming-nokia:1] Wait("Mobile/nokia-5985", "3") in new stack
[Jan  3 13:02:59] DEBUG[1663]: chan_mobile.c:1306 do_monitor_phone: rfcomm_read() (nokia) [+CIEV: 3,1]
[Jan  3 13:02:59] DEBUG[1663]: chan_mobile.c:1306 do_monitor_phone: rfcomm_read() (nokia) [+CIEV: 4,1]
   -- Bluetooth Device nokia has disconnected, reason (104).
   -- Executing [s@incoming-nokia:2] Answer("Mobile/nokia-5985", "") in new stack
]Jan  3 13:03:02] DEBUG[1666]: chan_mobile.c:981 rfcomm_write: rfcomm_write() (nokia) [ATA
[Jan  3 13:03:02] DEBUG[1666]: chan_mobile.c:986 rfcomm_write: rfcomm_write() error [9]

By: Josef Liska (phokz) 2008-01-03 07:52:58.000-0600

Hello,
I updated my test machine os from Ubuntu 7.04 to Ubuntu 7.10. This version
comes with kernel 2.4.22 and bluez 3.19.

I was able to receive few incoming calls with n6230i, with good sound quality,
no echo and normal latency.

By: Dave Bowerman (dbowerman) 2008-01-08 06:50:52.000-0600

ok,

so apart from the disconnect on hangup, has this issue gone away?

the version of bluez-libs you use is key. there have been a lot of audio bug fixes lately and its best to use the latest from bluez-org.

By: Josef Liska (phokz) 2008-01-08 07:16:47.000-0600

Yes, it seems to work well.


Once or twice mobile phone disconnected and reconnected after receiving SMS, but this is minor problem and I cannot reproduce it.

Other minor problem (maybe some error in my naive dialplan) is signaling and/or early media on outgoing calls. When I place a call to number with early media,
it just rings. When I place a call to busy/unavailable number, normaly there is a message "The number you are calling blah blah blah", but with chan_mobile it also just rings.

Everything else I tested (outgoing/incoming calls with N6230i, sms sending/receiving) works as expected.

By: Vladimir Latyshev (latysheff) 2008-01-09 01:58:13.000-0600

phokz,
when I tested Nokia 6230i, there was a problem with incoming calls: sound always goes to mobile speaker, not to Asterisk. Have you noticed such a behavior?
If not, I guess something was wrong with mobile firmware or my version of bluez-lib.
By the way, the only model (of about 20 tested) I've found which supported all features of chan_mobile was Nokia 6021 (( Mostly, they don't support sms.



By: Josef Liska (phokz) 2008-01-09 02:42:33.000-0600

latysheff: it is time to make a chan_mobile wiki, where testers and users could write about their results. I'd be interested in tested phones database.

I got exactly the same behavior you write about with N6230i when
a) compiled trunk chan_mobile with asterisk 1.4 and did not resolve changed symbols. In this case, asterisk stops, but call goes on through speaker
b) with older bluez-libs and/or older phone firmware when I got disconnect "104"
c) older version of everything (chan_mobile, asterisk, bluez-libs) suffered from
bug I reported as http://bugs.digium.com/view.php?id=10508. In that case asterisk crashed, but call continued through speaker.

My current firmware is 3.89. Old one was 3.40.

By: Vladimir Latyshev (latysheff) 2008-01-11 02:35:46.000-0600

phokz, I think
http://www.voip-info.org/wiki/index.php?page=Asterisk+Bluetooth+channels is good place for compatibility list

I've noticed, that latency is produced by not setting nocallsetup=yes
In that case there is no early audio and big latency. So trivial!

ps
Continue testing. Incoming calls on my Nokia 6021 mostly go to speaker. Sometimes to asterisk. Guess, there's some incompatibility with libbluez (currently 3.24), because 1) N6021 works fine in Windows XP with same bluetooth device 2) another phone, N6131 works fine with same Linux+Asterisk installation.

pps
Moreover, incompatibility somehow connected with SIM that I used! After changing SIM all goes perfect.
So, it's not the BUG of chan_mobile, sure. But _maybe_ something can be done to avoid it..



By: Josef Liska (phokz) 2008-01-17 05:20:44.000-0600

latysheff: could you post table of hardware you tested?
Either on Asterisk Bluetooth channels wiki or maybe here.

I'm thinking of buying another test mobile and don't know which one I should buy.

By: Vladimir Latyshev (latysheff) 2008-01-17 07:18:47.000-0600

phokz, http://www.voip-info.org/wiki/view/chan_mobile
I'm not sure I can post other info there - at leas I must retest all of those models. mail me  - latysheff at gmail dot com

David, we need official forum! Please install one kindly on http://www.chan-mobile.org/. PunBB is lite enough and cute.

By: Josef Liska (phokz) 2008-02-04 07:39:40.000-0600

Hello,
I retested the disconnect after hangup issue with latest trunk of both asterisk and chan_mobile. The issue is still there. Can this be connected with
http://bugs.digium.com/view.php?id=11566 ?

With this line commented out it works:

                              if (strstr(buf, "OK") || strstr(buf, pvt->ciev_call_0)) {
                                       /* close(pvt->sco_socket); */
                                       pvt->sco_socket = -1;
                                       pvt->state = MBL_STATE_IDLE;
                               }

If some other thread used pvt->sco_socket and it was closed, but not yet set to -1, it could possibly do something unintended.

By: Antonio Gallo (agx) 2008-03-18 03:08:37

I can confirm the same problem with asterisk-addons-1.6.0-beta2 and Nokia 6280  
Commeting out the line above will solve my problem.

By: snuffy (snuffy) 2008-08-22 03:03:09

dbowerman Any updates on this?

By: Leif Madsen (lmadsen) 2008-10-22 10:33:37

Pinging this issue again. Should we presume you are no longer able to update chan_mobile issues?

By: Leif Madsen (lmadsen) 2008-10-27 12:07:54

I'm not entirely sure why this is set to Ready For Testing as there is no patches assigned to this issue that I can see. Setting back to acknowledged. Unassigning dbowerman as he appears to be MIA.

By: jongerenchaos (jongerenchaos) 2008-11-07 12:13:28.000-0600

Sometimes when the connection is open, the sounds is broken after some minutes (between 20 and 50 minutes). With short calls there are no problems.

If you disconnect the connection between bluetooth phone and a incomming call  the bluetooth connection will not close.The bluetooth connection remains open between the bluetooth phone and asterisk and will not close.

Is this patch also the solution to tackle this problem?

By: Leif Madsen (lmadsen) 2008-11-07 12:42:07.000-0600

jongerenchaos: I don't believe there is any patch here at all

By: Matthew Nicholson (mnicholson) 2009-03-19 10:15:40

Please test with the trunk version of asterisk-addons and let me know if it resolved your issue.

By: Nicola Turato (nikkk) 2009-03-26 16:21:59

Hi guys, I have tested the latest trunk version of addons (r823) and there are some relevant issues:

- chan_mobile.so can't be loaded, there is an error on ast_string_copy(chan->exten, "s", AST_MAX_EXTENSION);  should be ast_copy_string...

- There is a synchronization problem (I think) with write/read of AT commands : randomly asterisk 1.6.1-branch-r184387 crashes with a segmetation fault sending ATD or Hangup. I have also tried with other asterisk versions.


Now the audio connection quality is very good and dtmf recognition works well.
Soon I'll give you all details of my tests.

Nicola

By: Matthew Nicholson (mnicholson) 2009-03-26 16:59:48

Ok, I fixed the ast_string_copy() thing with r824.  That was not happening on my (older) version of trunk.  I'll look into the hangup thing.

By: Nicola Turato (nikkk) 2009-03-30 05:06:12

Test System:

Fedora 10 Kernel 2.6.27.19-170.2.35
Bluez 4.30
Asterisk SVN-branch-1.6.1-r184345

Conceptronic usb 2.0 CBTU2A, Samsung GT-C6620

Logs:

--- DIAL PHASE ---


[Mar 30 10:50:22] DEBUG[26641]: pbx.c:3174 pbx_extension_helper: Launching 'Dial'
   -- Executing [903498727189@default:1] Dial("SIP/204-09beb688", "Mobile/GT-C6620/XXXXXXXXX,50,Ttr") in new stack
[Mar 30 10:50:22] DEBUG[26641]: rtp.c:2129 ast_rtp_make_compatible: Channel 'Mobile/GT-C6620-3925' has no RTP, not doing anything
[Mar 30 10:50:22] DEBUG[26641]: channel.c:3975 ast_channel_inherit_variables: Not copying variable DIALEDTIME.
[Mar 30 10:50:22] DEBUG[26641]: channel.c:3975 ast_channel_inherit_variables: Not copying variable ANSWEREDTIME.
[Mar 30 10:50:22] DEBUG[26641]: channel.c:3975 ast_channel_inherit_variables: Not copying variable DIALEDPEERNAME.
[Mar 30 10:50:22] DEBUG[26641]: channel.c:3975 ast_channel_inherit_variables: Not copying variable DIALEDPEERNUMBER.
[Mar 30 10:50:22] DEBUG[26641]: channel.c:3975 ast_channel_inherit_variables: Not copying variable DIALSTATUS.
[Mar 30 10:50:22] DEBUG[26641]: channel.c:3975 ast_channel_inherit_variables: Not copying variable SIPCALLID.
[Mar 30 10:50:22] DEBUG[26641]: channel.c:3975 ast_channel_inherit_variables: Not copying variable SIPDOMAIN.
localhost*CLI>
Disconnected from Asterisk server
Executing last minute cleanups
Asterisk ending (0).

Dial from cellphone proceed as normal ... asterisk dies

dmesg:

asterisk[26641]: segfault at c ip 001e963d sp b752a360 error 6 in chan_mobile.so[1df000+11000]




--- HANGUP PHASE ---


[Mar 30 10:54:20] DEBUG[26686]: chan_mobile.c:1647 sco_write: sco_write()
[Mar 30 10:54:20] DEBUG[26686]: chan_mobile.c:1647 sco_write: sco_write()
[Mar 30 10:54:20] DEBUG[26676]: chan_sip.c:19557 handle_incoming: **** Received BYE (8) - Command in SIP BYE
[Mar 30 10:54:20] DEBUG[26676]: chan_sip.c:2643 sip_alreadygone: Setting SIP_ALREADYGONE on dialog d32ca005-4e0a2098@localhost
[Mar 30 10:54:20] DEBUG[26676]: chan_sip.c:19058 handle_request_bye: Received bye, issuing owner hangup
[Mar 30 10:54:20] DEBUG[26676]: chan_sip.c:2868 __sip_xmit: Trying to put 'SIP/2.0 20' onto UDP socket destined for 192.168.3.104:5060
[Mar 30 10:54:20] DEBUG[26686]: channel.c:4482 ast_generic_bridge: Didn't get a frame from channel: SIP/204-0943dc88
[Mar 30 10:54:20] DEBUG[26686]: channel.c:4903 ast_channel_bridge: Bridge stops bridging channels SIP/204-0943dc88 and Mobile/GT-C6620-f54d
[Mar 30 10:54:20] DEBUG[26686]: channel.c:1641 ast_hangup: Hanging up channel 'Mobile/GT-C6620-f54d'
[Mar 30 10:54:20] DEBUG[26686]: chan_mobile.c:952 mbl_hangup: [GT-C6620] hanging up device
[Mar 30 10:54:20] DEBUG[26686]: chan_mobile.c:960 mbl_hangup: Closing SCO socket
[Mar 30 10:54:20] DEBUG[26686]: chan_mobile.c:966 mbl_hangup: Sending HANGUP
[Mar 30 10:54:20] DEBUG[26686]: chan_mobile.c:1338 rfcomm_write_full: rfcomm_write() (21) [AT+CHUP
localhost*CLI>
Disconnected from Asterisk server
Executing last minute cleanups
Asterisk ending (0).


Hangup on cellphone is done correctly ... asterisk dies

dmesg:

asterisk[26686]: segfault at c ip 00239031 sp b75ee3a0 error 6 in chan_mobile.so[22f000+11000]



By: Matthew Nicholson (mnicholson) 2009-03-30 08:27:00

Hmm. That is odd.  Can you upload a backtrace of the crash. Instructions follow.

Thank you for your bug report. In order to move your issue forward, we require a backtrace from the core file produced after the crash. Please see the doc/backtrace.txt file in your Asterisk source directory.

Also, be sure you have DONT_OPTIMIZE enabled in menuselect within the Compiler Flags section, then \'make install\' after enabling, reproduce the crash, and then execute the instructions in doc/backtrace.txt.

When complete, attach that file to this issue report. Thanks!

By: Nicola Turato (nikkk) 2009-03-30 09:28:28

See attached crash_bt.txt, thanks

By: Matthew Nicholson (mnicholson) 2009-03-30 17:32:03

Please apply the debug1.diff patch, recompile (make clean, make, make install).  Then reproduce the crash with debug level 2 on and upload the debug log and the backtrace.  Also be sure to include the 'thread apply all bt full' version of the trace.  Unfortunately, chan_mobile does not include an option to be built without optimizations.  The included patch works around this.

By: Nicola Turato (nikkk) 2009-03-31 04:46:43

I have uploaded all reqd files.

Nicola

By: Matthew Nicholson (mnicholson) 2009-03-31 11:41:59

Thanks for the prompt response.  Please post the output of 'print pvt', 'print *pvt', 'print pvt->msg_queue', and 'print pvt->msg_queue.first'.  Also, how often does this happen?

By: Nicola Turato (nikkk) 2009-04-01 05:18:21

I have attached a file with 'print ...' output. Frequently, 80% of my tests failed with an hangup crash at the end.

By: Matthew Nicholson (mnicholson) 2009-04-01 08:16:16

Ok, thanks.  It looks like something is overwriting part of the pvt structure.  Let me do some more testing.  Perhaps valgrind could be of use here.

By: Nicola Turato (nikkk) 2009-04-01 09:51:32

Hi, I have tried to comment this section:

static void msg_queue_free_and_pop(struct mbl_pvt *pvt)
{
       /*
       struct msg_queue_entry *msg;
       if ((msg = msg_queue_pop(pvt))) {
               if (msg->data)
                       ast_free(msg->data);
               ast_free(msg);
       }*/
}

Now crashes are gone!...ummm obviously AT messages are not managed well...

By: Matthew Nicholson (mnicholson) 2009-04-01 14:52:31

Please reproduce this and check if it crashes in the same place every time.

By: Nicola Turato (nikkk) 2009-04-02 10:35:16

Not same place, please see attached file.

By: Matthew Nicholson (mnicholson) 2009-04-03 12:34:32

Hmm... Are you using the phone to send SMS messages?

By: Nicola Turato (nikkk) 2009-04-06 01:52:46

No, I make voice calls only

By: Nicola Turato (nikkk) 2009-04-06 05:52:54

Please change AST_LIST_INSERT_TAIL(&pvt->msg_queue, msg, entry); (2 times) into AST_LIST_INSERT_HEAD(&pvt->msg_queue, msg, entry);

No more crashes :)

By: Matthew Nicholson (mnicholson) 2009-04-06 07:36:24

That change will break other things possibly.

By: Nicola Turato (nikkk) 2009-04-06 09:23:23

Ok, I agree but could be an AST_LIST_INSERT_TAIL bug?

By: Nicola Turato (nikkk) 2009-04-06 10:18:50

No crashes inserting "msg->entry.next = NULL;" before "AST_LIST_INSERT_TAIL(&pvt->msg_queue, msg, entry);"

By: Matthew Nicholson (mnicholson) 2009-04-06 10:44:26

Ok.  Good work.  I am looking into this now.  Looking at the documentation for AST_LIST_INSERT_TAIL, it appears that it does not initialize the values in the inserted list element, so entry.next would not get initialized.  So later when AST_LIST_REMOVE_HEAD is called and entry.next is used, msg_queue is incorrectly set.  This may be what is causing the crashes.  I have tweaked the way this works in svn trunk.  Please update to addons trunk and see if you have the same crash.

By: Nicola Turato (nikkk) 2009-04-08 03:30:03

No crash, thanks :)

By: Matthew Nicholson (mnicholson) 2009-04-08 14:24:50

Ok.  Now that we have solved the crash issue, is audio quality improved and are you still getting a disconnection after hangup?

By: jongerenchaos (jongerenchaos) 2009-04-08 15:31:55

For me: When the phone is disconnect it will succesful connect again!

By: Matthew Nicholson (mnicholson) 2009-04-08 15:36:41

jongerenchaos,

If you are still getting a disconnection after hangup with the latest addons svn trunk, please apply the debug1.diff patch and produce a debug log (with debug level 2) of a disconnect.

By: Nicola Turato (nikkk) 2009-04-09 05:20:29

Audio quality is improved.
Till now with all nokia models (E61,N73,E65) I see a disconnection after hangup, but reconnection is fast and reliable.

By: Matthew Nicholson (mnicholson) 2009-04-09 10:03:29

nikkk,

Can you attach a debug log of the disconnect?  This may just be standard behavior for those phones.

By: Nicola Turato (nikkk) 2009-04-09 11:34:38

Yes should be, but I suspect also a kernel/bluez combination issue.

...

[Apr  9 18:23:01] DEBUG[9966]: chan_mobile.c:952 mbl_hangup: [E61] hanging up device
]Apr  9 18:23:01] DEBUG[9966]: chan_mobile.c:1332 rfcomm_write_full: rfcomm_write() (27) [AT+CHUP
 == Spawn extension (default, 91XXXXXXXXX, 1) exited non-zero on 'SIP/104-082e09f8'
[Apr  9 18:23:01] DEBUG[9936]: chan_mobile.c:3416 do_monitor_phone: [E61] error reading from device: Connection reset by peer (104)
   -- Bluetooth Device E61 has disconnected.
   -- Bluetooth Device E61 has connected, initilizing...
]Apr  9 18:23:19] DEBUG[9995]: chan_mobile.c:1332 rfcomm_write_full: rfcomm_write() (27) [AT+BRSF=4

...

Nothing more



By: Matthew Nicholson (mnicholson) 2009-04-09 11:45:12

nikkk,

It looks like the phone is killing the rfcomm connection (with out responding to our AT+CHUP).  I don't know if there is anything I can do in chan_mobile to prevent this.  I am marking this as fixed.

By: Matthew Nicholson (mnicholson) 2009-04-09 11:46:03

Audio quality issues resolved.  Disconnect after hangup is normal on some phones (observed with Nokia phones thus far).