Asterisk 1.8 + Multiple GV accounts is complete. Inbound and outbound calls are easily resolved right now.
YH作者: bubblestar 時間: 2011-9-27 10:23
本帖最後由 bubblestar 於 2011-9-27 10:26 編輯
Curious to know the Caller ID display status in the incoming settings. In your configuration of [from-gv], you use account@gmail.com. Can we expect to see the REAL Caller ID number on our telephone set when someone dial in? Or we can only see the Google Voice's server telephone number instead. I ask because I use the following settings and it can show the real caller id number. Yours is neat and easier for everyone to understand. If it can generate the same effect, I would rather take yours.
[from-gv]
exten => _[@Xa-z].,1,Noop(Incoming Google Voice call for ${EXTEN})
same => n,Set(CALLERID(number)=${CALLERID(name):2:10}) ; make known of the calling party
same => n,Set(CALLERID(name)=${CALLERID(number)})
same => n,Answer()
same => n,Wait(2)
same => n,SendDTMF(1)
same => n,Dial(SIP/1001,30)
exten => h,1,Hangup()
複製代碼
作者: 角色 時間: 2011-9-27 11:38
For the time being, my Siemens IP shows a complete incoming caller information on phone LCD. I believe that we have to cut off some characters from it in order to show it correctly, for example +1 (xxx) yyy zzzzz.
I know that there are some script can handle it.
YH作者: bubblestar 時間: 2011-9-27 13:50
What I mean is real CALLER's Number ID instead of GV Server's Caller number. The latter one is useless to me. My existing script can handle it very well with correct number. Since your script seems less complicated so that why I ask whether it can indicate REAL CALLER NUMBER ID like mine. If it does, I will follow yours.
Sorry for my poor explanation.作者: ckleea 時間: 2011-9-27 14:20
Thank you very much and the program code has been modified accordingly.
YH作者: ckleea 時間: 2011-9-27 22:32
本帖最後由 ckleea 於 2011-10-2 12:28 編輯
Bubblestar has indeed given the code for quite sometimes. My original codes can show callerid as 1xxxxxxxx@voice.goggle.com-mcxmnvmvnm.
Applying this modification, the callerid is now 9 digits US number
A further modification is to
Set(CALLERID(number)=${CALLERID(name):1:11})
This will show up 11 digits including US country code 1作者: bubblestar 時間: 2011-9-27 23:57
Thanks ckleea for his effort to modify the GV incoming code. Now we have an easy-to-read script to handle and generate caller id number display in a familiar and correct format.作者: 角色 時間: 2011-9-28 01:30
With ckleea's and bubblestar's effort, the example would not be so complete such that other members who have to develop Asterisk 1.8 with multiple GV accounts may use it as an initial reference.
Curious to know the reason why both "allowguests = yes" and "allowguest = no" appeared in the [general] section of gtalk.conf.作者: 角色 時間: 2011-9-30 15:14
I just copied from the example and I am sorry that I do not know the exact meaning of each of them. Perhaps, we have looked into the sample file for gtalk.conf.sample.
Since the total telephone number including the country code 1 is 11 digits instead of 10, another modification should be made as below to indicate all numbers. Otherwise, the last digit will be truncated. Would ckleea c-hing put this into his script to reflect the whole picture for our future reference. Thanks.
Set(CALLERID(number)=${CALLERID(name):1:11})
This will show up 11 digits including US code 1
If users do not want to show all 11 digits on the screen display, the code should be:
Set(CALLERID(number)=${CALLERID(name):2:10})
This will show up 10 digits excluding US code 1作者: ckleea 時間: 2011-10-2 12:29