星号呼叫流程

时间:2014-10-26 08:13:00

标签: android sip asterisk voip

我想使用星号服务器进行从/到Android应用程序的SIP / VOIP调用。我搜索了很好的Sip客户端,发现CSip简单就好了。

假设有2个用户A和B.

  • 当A打电话给B时,
    • 向内部服务器发送请求
    • 内部服务器将通过填充某些数据库值来检查A是否可以呼叫B
    • 如果是,服务器将询问B是否要接受来自A
    • 的呼叫
    • 如果是,服务器将在A和B之间设置呼叫

我应该如何在星号中配置这些东西来实现这一点,并且还想知道如果CSipSimple最适合Android?

如果我在任何地方都错了,请纠正我。

由于

1 个答案:

答案 0 :(得分:2)

CSipSimple最适合Android。

对于星号,我试着解决你的问题。请尝试以下配置进行通话。

假设有2个用户A和B.

用户服务器

  

修改了服务器extension.conf

[my_outgoing]
//exten => _X.,1,Dial(SIP/${EXTEN})  
exten => _X.,1,AGI(test.php)  
// test.php is check for balance of A and if A having enough balance then it will call B from this file it self
  

修改了服务器sip.conf

[2221]
username=2221
type=friend
secret=2221
host=dynamic
context=my_outgoing
  

修改后的B服务器extension.conf

[my_incoming]
//exten => _X.,1,Answer()
exten => _X.,1,AGI(test2.php)
// Here test2.php is for run IVR from script and give user for press 1 or 2 to accept and reject the call etc...  
// if you are using the real device or soft phone then it will handle the call option by it self  
// If you have to handle this using script then code to handle call written into this  
// And if GUI [from soft phone] is there to handle call then write bellow line only     

exten => _X.,1,Dial(SIP/${EXTEN})
  

修改B服务器sip.conf

[2222]
username=2222
type=friend
secret=2222
host=dynamic
context=default

现在尝试注册来自不同设备的两个用户并尝试拨打电话。 致电A(2221)至B(2222)

相关问题