chan_mobile and W300i

Hi,

I’m trying to use a mobile phone (ericsson W300i) with asterisk through
bluetooth. After some sutrggling, I foun chan_mobile.

As some one already used this mobile with what result?

I’m considering a simple asterisk system (for home use/test purpose) with :

  • one SIP service provider (with link to PSTN)
  • one SIP phone (a softphone on the asterisk box)
  • one mobilephone (ericsson W300i) let’s call it A (for Asterisk)

Mobile A is supposed to be connected to asterisk.

I want to interact with this system with another mobile B. The idea would be
to use free calls between mobile A and B and use the SIP provider
mobile B => … => SIP provider (low cost call) to PSTN…

It is not yet very clear what’s working here. I think, I was able to call
mobile B :
SIP phone => asterisk => mobile A => mobile B
and the comunication is started between :
SIP phone and mobile B

The other way seems more complicated, as I will need to put a password for
security but when from mobile B (or a regular phone), I call mobile A, I did
not succeed in dialing the password., it looks like nothing is passing by.
Maybe I could spy to listen to what’s received by asterisk?

I’m using asterisk and chan_mobile from asterisk retrieve by svn checkout
around 5/1/2008 on a gentoo box. For bluetooth, I have bluez-utils-2.25
bluez-libs-2.25. Should I really update bluez ?

To try to get some more debug information I tried :
core set debug 4

But I didn’t get much?

W300i handfreeprofile seems to be on port 4 and it was not detected it was
detected (port=0)

Here are some config I use :

more /etc/bluetooth/hcid.conf


options {
        autoinit yes;
        security auto
        pairing multi;
        passkey "XXXX";
        pin_helper /etc/bluetooth/pin-helper;
}
device {
        name "Asterisk PBX"
        class 0x000100;
        iscan enable; pscan enable;
        lm accept;
        lp rswitch,hold,sniff,park;
}

more mobile.conf

[general]
interval=10   ; Number of seconds between trying to connect to devices.

[adapter]
id=intuix
address=00:11:67:2E:B4:XX
[W300i]
address=00:16:B8:5F:C2:XX ; the address of the phone
port=4 ;handfreeprofile       ; the rfcomm port number (from mobile search)
;port=5 ;headset profile
context=frommobile
adapter=intuix     ; adapter to use
dtmfskip=60
group=1       ; this phone is in channel group 1

more sip.conf

[general]
defaultexpirey=1800
dtmfmode=auto
qualify=yes
context=default
srvlookup=yes

register => _________:***********@freephonie.net
disallow=all
allow=ulaw
allow=alaw     ; Allow codecs in order of
allow=ilbc     ; preference
allow=gsm
allow=speex

[sip-out]
type=peer
host=freephonie.net
username=XXXXXXXXXX
fromuser=XXXXXXXXX
secret=**********
nat=yes

[sip-in]
type=peer
context=fromsipproxy
host=freephonie.net

[1000]
type=friend
secret=********
qualify=yes    ; Qualify peer is not more than 2000 mS away
nat=no         ; This phone is not natted
host=dynamic   ; This device registers with us
canreinvite=no ; Asterisk by default tries to redirect
context=fromsoftphone
port=5061     ; Uncomment this line if Ekiga and Asterisk are on the same host

more extensions.conf

[code]

[globals]
HOMEPHONE=XXXXXXXXX
MOBILEA=Mobile/W300i ;the mobile connected to asterisk
MOBILEB=Mobile/W300i/XXXXXXXXX ;the “remote” mobile
SIPOUT=SIP/sip-out
SOFTPHONE=SIP/1000
TIMEOUT=2

[general]
autofallthrough=yes

[fromsoftphone]
exten => 0,1,Answer()
exten => 0,n,Authenticate(XXXX)
exten => 0,n,Dial(${MOBILEB},30)

[frommobile]
exten => s,1,Answer()
exten => s,n,Authenticate(XXXX)
exten => s,n,Dial(${SOFTPHONE},45)

[fromsipproxy]
exten => s,1,Answer()
exten => s,n,Authenticate(XXXX)
exten => s,n,Dial(${MOBILEB},45)[/code]

Hope someone call help a bit!
I’d be gratefull!

By the way is there a list of mobile phone (even if unofficial) know to behave
well with chan_mobile/asterisk ? I heard that ericsson mobile doesn’t behave
very well?

Ok, I made some tests

Configuration tests

xlite <> asterisk <> mobile 1(bluetooth) <> mobile2

  • it works only if one make noise on the asterisk side (I used xlite for this test).
    **Can not pass password to asterisk through mobile 1. If no password, audio flux pass only in direction asterisk>mobile, mobile>asterisk : not OK.
    *** about 3 second lag if there is a sound on the asterisk side. If not, there is around 10 second lag

There is clearly a problem with the audio that is coming from the mobile.

I’d like to know if there some succesfull user of chan_mobile out there? or if it is too experimental yet ? or is there a better place to discuss chan_mobile related stuff? :smiley:

I’m using bluez-utils 2.x and I tried a bit the 3.x version but it looks like it was worse (there is no sdpd in gentoo installation) I don’t know if that’s a problem?!?

Ok, I got a 2.6.23 vanilla kernel and applied patch patch-2.6.23-mh1.gz from bluez.org/patches.html because I’ve seen that it solve some audio issues and I installed latest sble version of bluez 3.24.

The results is almost the same the problem is in red (yellow is OKAY) :

[size=150]Mob B [color=yellow]<>[/color] Mob A [color=yellow]<[/color][color=red]>[/color] asterisk [color=yellow]<>[/color] x-lite[/size]

the red [color=red]>[/color] has 9 second lag if there is no sound from x-lite or 3 second if there is some sound from x-lite !!
I’m going to post a bug!

All other “<” or “>” are fine!

Here the bug :
bugs.digium.com/view.php?id=11801