[toc]
SIP and NAT
On the phone (n900 maemo):
- username: foo@home.example.org (where example.org is my domain at home)
- use whatever option for keep-alive
- use "discover public IP"
On the Asterisk server, sip.conf :
[general] ... externhost=home.example.org localnet=192.168.1.0/255.255.255.0 [foo] type=friend username=foo secret=mypassword regexten=1234 callerid=("John Doe" <1234>) qualify=yes ; force keep-alives host=dynamic nat=yes canreinvite=no ; do not allow bridging of connections disallow=all allow=ulaw allow=gsm
On the firewall:
- allow incoming traffic on port 5060 (SIP) as well as 10000 to 20000 (RTP).
If you can connect the call, but you do not have audio, it is likely an RTP issue.
Debugging:
- sip set debug on
- rtp set debug on
Codecs
Codec | Bit rate | Description |
---|---|---|
G.711 | 64 kbps | 1970s POTS standard, including u-law (North America + Japan) and a-law (Europe) |
G.729 | 8 kbps | similar to G.711, slightly lower quality, uses less bandwidth, but requires more CPU to compress, so some phones cannot support more than one call at the time | 8 kbps |
G.722 | 48/56/64Kbps | HD Audio, more recent |
Reference: voip-info.org: Asterisk codecs