lol官方插件:asterisk 连接 华为 E169 GSM 无线上网卡

来源:百度文库 编辑:中财网 时间:2024/04/29 04:04:40

asterisk 连接 华为 E169 GSM 无线上网卡[复制链接]

toasterisk当前离线
注册时间
2009-3-3
最后登录
2011-11-9
在线时间
386 小时
阅读权限
200
积分
94
帖子
1705
精华
2
UID
130
IP卡 狗仔卡

管理员

  • 串个门
  • 加好友
  • 打招呼
  • 发消息
1#toasterisk发表于 2009-5-16 19:14:24|只看该作者|倒序浏览.pcb{margin-right:0}Dear friends,

I think you should have a look at this.

http://groups.google.es/group/asterisk-es/browse_thread/thread/a29e38faae041f33#

Odicha has developed a new driver to use Huawei modems as asterisk
trunks. This is really cool, as you don't need to buy a gateway and a
fxo port, and it is great for demos with a laptop, for example.
This modems are cheap, and even Vodafone gives them for free to many
companies here.

Huawei E169 and K3520 are the only models that support voice, so other
models just work for sms.

First I needed to upgrade my modem to the latest firmware, which you
can get here:

http://www.vodafone.de/hilfe-support/technischer-support/97002_131991.html

Then you need to download chan_sebi.zip, extract it, copy the
sebi.conf file to /etc/asterisk and the chan_sebi.c file to the source
asterisk-addons-xxx/channels directory. Then recompile and install.
After that you need to detect the data port. You can do it with
minicom, or use this small script:

# This is how you get the dataport
for i in `ls -1 /dev/ttyUSB*`;  do
stty -F $i |grep intr &>/dev/null
res=$?
if [  $res -eq 0 ]; then
dataport=$i
fi
done
echo $dataport

then you have to put your imei, pin, and your right data port in sebi.conf
you can also remove the pin from your sim, as I did, and then comment
out the pin line in sebi.conf

And last, you need to give asterisk user permissions to use the serial ports:

chmod 660 /dev/ttyUSB*
chown asterisk:uucp /dev/ttyUSB*
echo 'KERNEL=="ttyUSB[0-9*]", MODE="0660", OWNER="asterisk",
GROUP="uucp"'  >>  /etc/udev/rules.d/92-sebi.rules

Then you create a custom trunk in freePBX like:  sebi/huawei1/$OUTNUM$

Restart asterisk and you are ready to go.
You can see the connected devices from asterisk console with:

sebi show devices

You can see the logs with:
cat /var/log/asterisk/full |grep sebi


I still haven't tried the sms part, but I've been reported it works
fine.  SebiSendSMS  tech/channel|number|"message blabla"  it works as
the sms part in chan_mobile.

The driver is still in a beta stage, but I've just tried it and it
works very well and looks quite stable. Odicha is still working for
automatic detection when you have several modems and with udev rules
to make it work without problems, as when you reboot sometimes the
ports get changed and need to hand edit sebi.conf for the modems to
load. He has tried with 4 usb modems at a time without problems.

The cpu consumption is very low, less than 0.7% in a P4 1700MHz in my tests.

相关链接:
http://www.lolacolay.com/ramon/chan_sebi.zip
http://groups.google.es/group/asterisk-es/browse_thread/thread/a29e38faae041f33#
通过华为的gsm modem 就可以和asterisk 通信了。 赶紧抓住机会吧。
to*