chan_mobile help for install

Joined
Dec 3, 2007
Messages
8,069
Points
88
Code:
# tail -100 /var/log/messages | grep hcid
Jun 11 19:48:33 laruche hcid[4739]: pin_code_request (sba=00:0B:0D:82:26:A3, dba=00:17:E7:1D:F2:69)
Jun 11 19:49:37 laruche hcid[4739]: Unregister path:/org/bluez/hci0
Jun 11 19:49:37 laruche hcid[4739]: Unregister path:/org/bluez
Jun 11 19:49:37 laruche hcid[4739]: Exit
Jun 11 19:49:38 laruche hcid[4799]: Bluetooth HCI daemon
Jun 11 19:49:38 laruche hcid[4799]: Register path:/org/bluez fallback:1
Jun 11 19:49:38 laruche hcid[4799]: HCI dev 0 registered
Jun 11 19:49:38 laruche hcid[4799]: Register path:/org/bluez/hci0 fallback:0
Jun 11 19:49:38 laruche hcid[4799]: HCI dev 0 already up
Jun 11 19:49:38 laruche hcid[4799]: Device hci0 has been added
Jun 11 19:49:38 laruche hcid[4799]: Device hci0 has been activated
Jun 11 19:52:46 laruche hcid[4799]: Unregister path:/org/bluez/hci0
Jun 11 19:52:46 laruche hcid[4799]: Unregister path:/org/bluez
Jun 11 19:52:46 laruche hcid[4799]: Exit
Jun 11 19:52:46 laruche hcid[4895]: Bluetooth HCI daemon
Jun 11 19:52:46 laruche hcid[4895]: Register path:/org/bluez fallback:1
Jun 11 19:52:46 laruche hcid[4895]: HCI dev 0 registered
Jun 11 19:52:46 laruche hcid[4895]: Register path:/org/bluez/hci0 fallback:0
Jun 11 19:52:46 laruche hcid[4895]: HCI dev 0 already up
Jun 11 19:52:46 laruche hcid[4895]: Device hci0 has been added
Jun 11 19:52:46 laruche hcid[4895]: Device hci0 has been activated
Jun 11 20:00:02 laruche hcid[4895]: Unregister path:/org/bluez/hci0
Jun 11 20:00:02 laruche hcid[4895]: Unregister path:/org/bluez
Jun 11 20:00:02 laruche hcid[4895]: Exit
Jun 11 20:00:02 laruche hcid[5040]: Bluetooth HCI daemon
Jun 11 20:00:02 laruche hcid[5040]: Unknown option 'pin_helper' line 25
Jun 11 20:00:02 laruche hcid[5040]: syntax error line 25
Jun 11 20:00:02 laruche hcid[5040]: Register path:/org/bluez fallback:1
Jun 11 20:00:02 laruche hcid[5040]: HCI dev 0 registered
Jun 11 20:00:02 laruche hcid[5040]: Register path:/org/bluez/hci0 fallback:0
Jun 11 20:00:02 laruche hcid[5040]: HCI dev 0 already up
Jun 11 20:00:02 laruche hcid[5040]: Device hci0 has been added
Jun 11 20:00:02 laruche hcid[5040]: Device hci0 has been activated
Jun 11 20:03:15 laruche hcid[5040]: Unregister path:/org/bluez/hci0
Jun 11 20:03:15 laruche hcid[5040]: Unregister path:/org/bluez
Jun 11 20:03:15 laruche hcid[5040]: Exit
Jun 11 20:03:15 laruche hcid[5132]: Bluetooth HCI daemon
Jun 11 20:03:15 laruche hcid[5132]: Register path:/org/bluez fallback:1
Jun 11 20:03:15 laruche hcid[5132]: HCI dev 0 registered
Jun 11 20:03:15 laruche hcid[5132]: Register path:/org/bluez/hci0 fallback:0
Jun 11 20:03:15 laruche hcid[5132]: HCI dev 0 already up
Jun 11 20:03:15 laruche hcid[5132]: Device hci0 has been added
Jun 11 20:03:15 laruche hcid[5132]: Starting security manager 0
Jun 11 20:03:15 laruche hcid[5132]: Device hci0 has been activated
Jun 11 20:04:33 laruche hcid[5132]: Unregister path:/org/bluez/hci0
Jun 11 20:04:33 laruche hcid[5132]: Unregister path:/org/bluez
Jun 11 20:04:33 laruche hcid[5132]: Exit
Jun 11 20:04:33 laruche hcid[5191]: Bluetooth HCI daemon
Jun 11 20:04:33 laruche hcid[5191]: Register path:/org/bluez fallback:1
Jun 11 20:04:33 laruche hcid[5191]: HCI dev 0 registered
Jun 11 20:04:33 laruche hcid[5191]: Register path:/org/bluez/hci0 fallback:0
Jun 11 20:04:33 laruche hcid[5191]: HCI dev 0 already up
Jun 11 20:04:33 laruche hcid[5191]: Device hci0 has been added
Jun 11 20:04:33 laruche hcid[5191]: Starting security manager 0
Jun 11 20:04:33 laruche hcid[5191]: Device hci0 has been activated
Jun 11 20:05:52 laruche hcid[5191]: HCI dev 0 down
Jun 11 20:05:52 laruche hcid[5191]: Stopping security manager 0
Jun 11 20:05:52 laruche hcid[5191]: Device hci0 has been disabled
Jun 11 20:05:52 laruche hcid[5191]: HCI dev 0 unregistered
Jun 11 20:05:52 laruche hcid[5191]: Unregister path:/org/bluez/hci0
Jun 11 20:05:52 laruche hcid[5191]: Device hci0 has been removed
Jun 11 20:05:55 laruche hcid[5191]: HCI dev 0 registered
Jun 11 20:05:55 laruche hcid[5191]: Register path:/org/bluez/hci0 fallback:0
Jun 11 20:05:56 laruche hcid[5191]: HCI dev 0 up
Jun 11 20:05:56 laruche hcid[5191]: Device hci0 has been added
Jun 11 20:05:56 laruche hcid[5191]: Starting security manager 0
Jun 11 20:05:56 laruche hcid[5191]: Device hci0 has been activated
Jun 11 20:06:07 laruche hcid[5191]: pin_code_request (sba=00:0B:0D:82:26:A3, dba=00:17:E7:1D:F2:69)
Jun 11 20:06:25 laruche hcid[5191]: pin_code_request (sba=00:0B:0D:82:26:A3, dba=00:17:E7:1D:F2:69)
Jun 11 20:10:09 laruche hcid[5191]: pin_code_request (sba=00:0B:0D:82:26:A3, dba=00:17:E7:1D:F2:69)
Jun 11 20:21:19 laruche hcid[5191]: pin_code_request (sba=00:0B:0D:82:26:A3, dba=00:17:E7:1D:F2:69)
Jun 11 20:59:39 laruche hcid[6119]: Bluetooth HCI daemon
Jun 11 20:59:39 laruche hcid[6119]: Service could not become the primary owner.
Jun 11 20:59:39 laruche hcid[6119]: Unable to get on D-Bus
Jun 11 21:00:21 laruche hcid[5191]: pin_code_request (sba=00:0B:0D:82:26:A3, dba=00:17:E7:1D:F2:69)
 
Joined
May 28, 2009
Messages
595
Points
0
try with this risky yum:

Code:
yum update dbus*
Do you are using a testing machine ? hohoho.


gamba47
 
Joined
Dec 3, 2007
Messages
8,069
Points
88
It's on my server at home, so not testing server.

Code:
Dependencies Resolved

=============================================================================
 Package                 Arch       Version          Repository        Size
=============================================================================
Updating:
 dbus                    i386       1.1.2-12.el5     base              234 k
 dbus-glib               i386       0.73-8.el5       base              160 k
Installing for dependencies:
 dbus-libs               i386       1.1.2-12.el5     base              123 k

Transaction Summary
=============================================================================
Install      1 Package(s)
Update       2 Package(s)
Remove       0 Package(s)

Total download size: 518 k
Is this ok [y/N]: N
What's the risk?
 
Joined
May 28, 2009
Messages
595
Points
0
I broke again my box.

Don´t do this on production enviroment!

gamba47
 
Joined
Dec 3, 2007
Messages
8,069
Points
88
Hi, I'm rouse. :blink:

So, Your box is break because you've updated the dbus? :S
 
Joined
Dec 3, 2007
Messages
8,069
Points
88
Slowly, but....

After some search, we need to make:
# hcitool inq
To take the class number and put it here: /etc/bluetooth/hcid.conf


Restart : service bluetooth reload

and run:
Code:
dbus-send --system --type=method_call --print-reply --dest=org.bluez /org/bluez/hci0 org.bluez.Adapter.SetMode string:discoverable
method return sender=:1.8 -> dest=:1.9 reply_serial=2
Now you can discover your elastix server by the phone.

Now there's more information, and I think that it's on the good way.
 

Bob

Joined
Nov 4, 2007
Messages
2,400
Points
36
If I may, can I provide a bit of sanity to this thread.

Early in the piece (some of my early posts in getting Chan_mobile working are in this thread..I think??), I spent many, many hours trying to get chan_mobile working and pairing, and I literally mean many hours (20+).

Based on what I have seen, over the last year, the chan_mobile module is varied in success, especially in the pairing area. The main issue is that as a core module, it is very dependent on various libraries, which can impact on its success or failure. Furthermore its possible impact when further updates are applied to Asterisk or the Bluetooth Libraries, cannot guarantee that your Bluetooth connection will continue to work.

If you want to use this in a commercial situation, you would want a good long hard think about whether you would use this method or not. If a simple home solution, then go for it, it is always great to experiment, and get it working well, and who knows it may improve to the point that it is a great solution. In a commercial situation though, you want to know that upgrading things will not break it, even yum updates.

I looked for other low cost solutions that would perform the same task, give me no issues in upgrades, pair with almost any make of phone with Bluetooth, so that I could implement a solution with absolute confidence.

The product I came up with an tested is the Gempro GP-710 & GP-712 which is a SIP to BLUETOOTH gateway. The 710 is a single phone gateway and the 712 a two phone Gateway. Need four phones, then get 2 x 712. At a cost of $US180 and $US220, it doesn't take much calculation to work out that two hours spent on getting chan_mobile going, makes the ROI on these units worthwhile. The benefit is that these units perform the same tasks as what you were trying to achieve, except they connect via SIP, which as you can appreciate, is pretty well a constant on any upgrade. Further benefits are:

* Locate the Unit anywhere on your network (near a good Window, away from a computer room)
* Incoming CID works
* Incoming CLID works
* Visual signs of pairing (and pairing has worked on all phones that I have tried).
* Environmental issues seem to have no effect. Have moved phones away, turned them off, have power bounced the Gateway, every single time, has come back to normal operation.

For their price, they give a lot of confidence, and I have to admit it is one product where my initial expectations were not high (partly due to price and instruction manual), but it has exceeded my expectations.

Anyhow, just food for thought and another alternative. This message is not SPAM, I don't work for Gempro, just letting you know that there is something else out there as an alternative to the overpriced standard GSM Gsteways.....

Regards

Bob
 
Joined
Dec 3, 2007
Messages
8,069
Points
88
Hi bob, it's right.

This solution (bluetooth) is not very stable, and because, if you look the bluez version we are the old. (3.7) from rpm package, and 4.41 on web site bluez. So there's several fix bug (pairing..Etc)
There's not rpm package for this version.

Maybe it's this problem that we have!?

Maybe that exist with a version USB and not bluetooth! :side:
 
Joined
Mar 18, 2009
Messages
8
Points
0
Hi,

I now have a working mobile trunk, audio okay, bit of delay, but tolerable.

I had a devils time trying to get the incomming call answered by elastix. I eventually found that on my test box, I had used the same extension numbers as on my working box, albeit with different domain registration addresses (for the different boxes). (I started my test box with a backup from my working box, so that it would be an identical setup, for testing....)(and they did have different IP addresses.)

This worked fine for outgoing calls, but incoming calls were being lost, possibly getting confused somewhere..... As soon as I created new extension numbers for my test extensions, and deleted the common numbers, the incoming call into elastix, from my mobile, and was routed to my test extensions... :)

I still have a problem, of when the elastix box is rebooted (or amportal restart), my port for the mobile phone changes, requiring editing of mobile.conf and reloading. If the port does not change, then the phone reconnects seamlessly.

Most of my problems that I encountered, I believe, arose from my phone. (apart from my lack of knowledge-but that is another issue all together) Once I allowed the bluetooth device to answer calls, most of the issues went away.


I haven't been game enough to try updating any modules yet....
 
Joined
May 28, 2009
Messages
595
Points
0
danardf said:
Hi, I'm rouse. :blink:

So, Your box is break because you've updated the dbus? :S
I don´t think so. Maybe i make another change and broke it. I lost dahdi features con CLI :(


Bob: you are wright. This is the better way to fix the problem. In commercial enviroments it is not the best to do. Good equipment the Gempro GP-710 & GP-712 !

Keith_f: Can you post the steps to make it working ?


Regards

gamba47
 
Joined
Sep 20, 2008
Messages
10
Points
0
As I said earlier, the main problem is that, without the Passkey-agent, the only way to pair the 2 devices (Phone and Box) is to find your Box by searching on the phone, because when you try to connect, you will enter the pin 1234, a pin request will be sent to the BOX which will answer with 1234 (it's pre configured) and they will pair.

When you simply add the phone MAC to Mobile.conf and wait for the BOX to attempt to pair with your Mobile you will always be unsuccessful, because without the passkey-agent your BOX tries to pair with no pairing PIN, no matter what you enter on the phone, it always fails.

danardf said:
Slowly, but....

After some search, we need to make:
# hcitool inq
To take the class number and put it here: /etc/bluetooth/hcid.conf


Restart : service bluetooth reload

and run:
Code:
dbus-send --system --type=method_call --print-reply --dest=org.bluez /org/bluez/hci0 org.bluez.Adapter.SetMode string:discoverable
method return sender=:1.8 -> dest=:1.9 reply_serial=2
Now you can discover your elastix server by the phone.

Now there's more information, and I think that it's on the good way.
My main problem has always been how to make to BOX visible to a mobile search, none of the commands I've found allowed me to find the BOX by searching on the phone, if this really works, you might just have solved our problems.


@ Bob

I do believe that a Bluetooth to SIP is a whole lot more compatible to future updates, you will always configure an outgoing SIP trunk, which will probably never change.

The problem is, how cheap is this solution for people outside US? In my case (Brazil), I'd pay 220USD for the product, plus 45 USD shipping, plus 60% importation fee, plus 23% ICMS (Products with market value fee), plus buying the phones. 477,96 USD for 1 unit, wait 20 to 45 days for arrival. Against 30 USD of a bluetooth dongle (No fee are charged on products that cost less then 50 USD).


@ Keith_f

I knew something outside Asterisk-Bluetooth-Phone environment must be going on, it's not difficult to receive and make calls through the mobile custom trunk once you have the phone paired and ready.

Good luck to you and your new Bluetooth-GSM powered BOX.
 

Bob

Joined
Nov 4, 2007
Messages
2,400
Points
36
Coizado,

I do believe that a Bluetooth to SIP is a whole lot more compatible to future updates, you will always configure an outgoing SIP trunk, which will probably never change.

The problem is, how cheap is this solution for people outside US? In my case (Brazil), I'd pay 220USD for the product, plus 45 USD shipping, plus 60% importation fee, plus 23% ICMS (Products with market value fee), plus buying the phones. 477,96 USD for 1 unit, wait 20 to 45 days for arrival. Against 30 USD of a bluetooth dongle (No fee are charged on products that cost less then 50 USD).
I understand where you are coming from. They are some steep charges for importation.

In my case I brought one in at $US220, plus $US20 (EMS) Postage. It was received in 3 days. We have no major import taxes for under $1000. As for the phones, due to the "Global Recession" staff layoffs and the way that "Fleet mobile plans" work in Australia, is that many companies have quite a lot of spare mobile phones (usually the latest models), and spare sims, as it is cheaper for them to buy a minimum qty of phones and sims to achieve fleet pricing.

Unlike units like the GSM Gateways that take sims, as quite often they retool and produce a different run each time, and don't always have stock and also have delays, the GEMPRO units are generic, so their stock is pretty good.

For these units I also have Trunk configuration details for Elastix/Freepbx and the config that works on the Gempro. That alone took me a few hours, as the manual is useless, especially with phrases when they are discussing NAT setup such as "it baffles your firewall", but manual aside, solid little units.

Anyhow, as I said, I would like to see the chan_mobile working, and as soon as I have time available, I will re-look at the whole thing from top to bottom. Just wanted to make sure others are aware that other solutions are available.

Regards

Bob
 
Joined
Mar 18, 2009
Messages
8
Points
0
Hi all,

Mobile search, returns different results when used, See below, the command mobile search was typed in when I was trying to re-connect. The MAc addressees and names seam to change. Not only that, but the port changes as well..


Code:
elastix*CLI> mobile search
Address           Name                           Usable Type    Port
00:22:FC:EB:67:AC KeithsN96                      Yes    Phone   3
00:1E:3A:7B:99:05 Krisn95                        Yes    Phone   3
00:18:F3:2C:47:98 TOPAZ                          Yes    Headset 2
elastix*CLI> mobile show devices
ID              Address           Group Adapter         Connected State SMS
KeithsN96       00:22:FC:EB:67:AC 0     blue            No        Free  No 
elastix*CLI> mobile search
Address           Name                           Usable Type    Port
00:18:F3:2C:47:98 KeithsN96                      No     Headset 0
00:1E:3A:7B:99:05 TOPAZ                          No     Headset 0
00:22:FC:EB:67:AC KeithsN96                      Yes    Phone   3
elastix*CLI> mobile search
Address           Name                           Usable Type    Port
00:18:F3:2C:47:98 TOPAZ                          Yes    Headset 2
00:1E:3A:7B:99:05 Krisn95                        Yes    Phone   3
00:22:FC:EB:67:AC KeithsN96                      Yes    Phone   3
You can see that the second set has two "keithN96"'s, Topaz and Krisn95 mac addresses swap around...

So how can asterisk pair,when the "connection manager" gets confused??? (Not to mention me...)

The port number also, randomly changes as well. I answered a call from my phone. After the call my phone dropped out. When I checked, the port number had changed...

@ Bob,

the Gempro GP-712 looks good..

@ Gamba47

I wish I knew. Just when I think I know how to re-connect, the whole thing falls in a heap and I have to wade around again to re-connect.

Thanks all

Regards

Keith

PS I had all this typed in once already, but when I submitted I had been logged out.... rrr
 
Joined
Jun 24, 2009
Messages
11
Points
0
I bought GP-712 this product from Gempro before.
Voice qulaity is very good.
I use it to apply to 3G VoIP Gateway solution.
The solution price is quite low if compares to other related products.
 
Joined
Mar 18, 2009
Messages
8
Points
0
Hi all,

I have now obtained a GP-712 and have installed it and have it running using two mobile phones.

Thanks Bob for your info on the GP-710, without which I would still be annoying John and Ben...

I will leave the "chan_mobile" add-on alone for a while and catch up on some sleep.... although it would be good to get this working.

Thanks for your help.

Keith F.
 

Bob

Joined
Nov 4, 2007
Messages
2,400
Points
36
Keithf,

Good to hear that you have it working.

Just in case anyone else is reading this thread, the instructions to get the GP710/GP712 running are in another thread which is found at...

http://www.elastix.org/index.php?option ... 99&catid=1

Likewise, I too have have not abandoned CHAN_MOBILE. I just need some quality time to go through it in detail, but in the meantime, on a commercial basis, the GP710/712 have given me some breathing room.

Regards

Bob
 
Joined
Feb 3, 2010
Messages
28
Points
0
Just got my hands on this one yesterday. You are correct, the issue is passkey-agent.
This is not included in bluez rpm. All you have to do is download the src.rpm ->rpm2cpio->build on your own.
The passkey-agent.c file is inside hcid directory.

Once this is done you can execute passkey--agent --default PIN
where PIN is your PIN (i.e. passkey--agent --default 1234).
Then all bluetooth devices will be paired with default PIN 1234.

So, after compiling passkey-agent on my own I could pair my iPhone with my Belkin mini dongle and everything seemed ok.
I could receive incoming calls and use my iPhone as a trunk but in all cases I had no-audio. I could only hear audio when I pressed buttons on my soft-phone (x-lite). Any clues on this one?
 
Joined
Sep 20, 2008
Messages
10
Points
0
Hi there,

Well, after almost 1 year I've said the problem is the pass-key-agent some good soul finally teaches how to install it. Thank you very much!

On your 1-way audio problem, it's probably because you are not using an original DBT-120, I've had all sorts of problems trying to use other dongles. Until I finally got an DBT-120 from eBay and all weird problems were gone.

On the other hand, it's known that chan_mobile works better with nokia, so you might wanna try one.

Hope that helps.

Thanks again.
 

Staff online

Members online

Latest posts

Forum statistics

Threads
30,994
Messages
131,110
Members
17,716
Latest member
Orbit114
Top