But while i have to do configure it on every extension, i want it for all extensions for in- and outbound calls, never mind on status of the extension.
Can anybody point me to the right path to configure it?
hooking the dialplan seems the right way, but do you (or anybody) know how to solve this:
When my iPhone-App goes to background, it’s derigistered on freepbx. In this case the callers seen “call ended” immediately. So, it seems freepbx means there is no endpoint registered, and quit the call.
thanks for reply. I tried to investigate as good as i can. With sngrep i can see an INVITE from my extension 15 to 7 (7 is the mobile device). After this i’ll get an TRYING and then a “503 Service unavailable” back to ext. 15 (as i wrote “call ended”).
In the Logs i have this:
OPTIONS sip:[email protected]:62166;pn-prid=B0A9AE68135C1882-STRIPPED-DEVICE-ID-BD51D3B2CC6C4BAE045AA00062B:voip;pn-provider=apns.dev;pn-param=ABCD1234.com.company.esilphone.voip;pn-silent=1;pn-timeout=0;pn-msg-str=IM_MSG;pn-call-str=IC_MSG;pn-groupchat-str=GC_MSG;pn-call-snd=notes_of_the_optimistic.caf;pn-msg-snd=msg.caf SIP/2.0
From: <sip:[email protected]>;tag=22f5c4d8-d182-4a02-9d3f-d9eb793cde5f
To: <sip:[email protected];pn-prid=B0A9AE68135C1882-STRIPPED-DEVICE-ID-BD51D3B2CC6C4BAE045AA00062B:voip;pn-provider=apns.dev;pn-param=ABCD1234.com.company.esilphone.voip;pn-silent=1;pn-timeout=0;pn-msg-str=IM_MSG;pn-call-str=IC_MSG;pn-groupchat-str=GC_MSG;pn-call-snd=notes_of_the_optimistic.caf;pn-msg-snd=msg.caf>
I don’t know what asterisk is trying here every 2 seconds. But what i see is, asterisk knows my App (com.company.esilphone.voip : esilphone is the name of the App) and has a knowledge about the device token of my App
Asterisk has no implementation of push services or knowledge of it
Yes, i know. Thats why i have a script that triggers a push via APNS to the mobile on an incoming call. But because of “Service unavailable” immediately there is no chance to bring that call up.
I will check the peers after a time my App goes in background. There must be a reason why it’s not registered anymore or, like @david55 guessed, the mobile cancel the call.
I just investigate it a bit, and it seems because of app backgrounding the connection to asterisk is gone after a short time. Seems for me normal, because of battery drain. Here is the state of the peer:
To establish a call i have to send a push notification to the phone (type: voip). If i do so, my peer becomes available again, but it will not work as long asterisk shows the extension is not available for the caller…