This is a method of using CSipSimple to directly call your OBi and use single-stage dialling to use the OBi's trunks to place calls. I'm assuming that you are using a dynamic dns public ip address to access your router. (If you have a fixed public ip address, then there are easier methods.) You need a spare spX for this method – this example uses ITSP Profile B and sp2; its UserAgentPort is 5071. The CSipSimple account has a CName "mob2obi" and CallerID "12345678".
OBi setup:
Service Providers -> ITSP Profile B -> SIP -> ProxyServer : 127.0.0.1
Service Providers -> ITSP Profile B -> SIP -> X_SpoofCallerID : checked
Service Providers -> ITSP Profile B -> SIP -> X_DiscoverPublicAddress: Checked
Service Providers -> ITSP Profile B -> General -> DigitMap (typical example):
(1xxxxxxxxxx|<1>[2-9]xxxxxxxxx|xx.S3|[^*#]@@.'@'@@.)
Voice Services -> SP2 Service -> Enable : (checked)
Voice Services -> SP2 Service -> X_ServProvProfile : B
Voice Services -> SP2 Service -> X_RegisterEnable : (unchecked)
Voice Services -> SP2 Service -> X_KeepAliveEnable: checked
Voice Services -> SP2 Service -> X_KeepAliveExpires: 60
Voice Services -> SP2 Service -> X_KeepAliveServer:
stun.ideasip.com (or your choice)
Voice Services -> SP2 Service -> X_KeepAliveServerPort: 3478 (default)
Voice Services -> SP2 Service -> X_KeepAliveMsgType: stun
Voice Services -> SP2 Service -> X_UserAgentPort : 5071
Voice Services -> SP2 Service -> AuthUserName : 6789 (Anything, but not blank)
Voice Services -> SP2 Service -> CallerIDName : Whatever
Voice Services -> SP2 Service -> MaxSessions : 4
Voice Services -> SP2 Service -> X_InboundCallRoute (typical example):
{(12345678)>(Msp1):sp1},{(12345678)>**0:aa},{(12345678)>0:ph}
The X_KeepAlive settings will ensure that the OBi uses its public ip address as its SIP contact when you call in remotely. These settings may well be useful for other methods of direct ip calling.
The UserAgentPort does need to be forwarded in your router. Some routers may reject the incoming call on the basis that it appears to be unsolicited traffic.
In CSipSimple set up an account to call without registration:
1. Create a Local account – it just requires an account name.
2. Long press on the account name > Choose wizard > Expert.
3. Long press on the account name > Modify account. Expert will prompt you for Account id. For this example Insert "mob2obi<sip:12345678@127.0.0.1>"
4. Allow contact rewrite: uncheck.
5. Proxy URI – insert your dynamic dns plus UserAgentPort, such as "sip:my.dns.com:5071"
6. Leave all other account settings at default.
CSipSimple > Settings > Network > Resolve DNS SRV: checked
CSipSimple > Settings > Network > Enable STUN: checked
CSipSimple > Settings > Network > Incoming and Outgoing Calls – check relevant boxes. WiFi should be checked by default, add 3G if you wish to try it.
CSipSimple > Settings > Media – Set up codecs depending on which are supported by the voip providers you are likely to call. The OBi will act as a bridge, so it's a question of matching CSipSimple with your voip service providers, except for direct calls to the OBi (**0 for aa and 0 for phone), where you need to match your OBi. It's a good idea to try some of the less bandwidth hungry codecs such as ILBC, GSM and G729. G729 costs a few $ and comes as an app that auto integrates with CSipSimple.
Now, if you only have one CSipSimple account, you can dial from the CSipSimple dial pad as if you are on your home phone. Alternatively, if you have checked "Dialer integration", then you can dial from the native android dial pad and use your normal contacts. In this case, when you press the dial button, you will be asked to select the account to use – "CSipSimple account name" or " Use mobile".
Now you should be good to go. It works for me reliably from free wifi hot spots, so have a wander around the local coffee shops and cafes and try it