November 10, 2009

Use objdump to do library depency check

Generally, things that are trying to determine shared library
dependencies should use something like objdump, not ldd:

objdump -p $f | awk '/ NEEDED / { print $2 }'

November 6, 2009

bash history autocomplete

Add the following to your .bashrc file.

# make bash autocomplete with up arrow
bind '"\e[A":history-search-backward'
bind '"\e[B":history-search-forward'

A good tcp serial port server on Linux: remserial

This Linux Serial port (RS232) server is simple and works great. check it out.

remserial at

Another good one is ser2net. Project page in source forge:

Yet another one: serproxy at
this one supports Windows too.

November 4, 2009

Linux process view: top and htop

htop is a nice program to view linux processes, an alternative and simpler top.

November 3, 2009

Fix IP Phone for Gizmo

You may want to test first by dialing *0# and you will get one of two recordings.

1. You are behind the router that uses a NAT. You may experience call completion problems behind this router:
2. You are behind the SIP compatible router. You are now ready to make free world-wide calls to other SIP phones...:

From Boatman on the Gizmo forum: Suggested settings for ATAs behind one or more NAT routers.

(under SIP tab)
Handle_VIA_received: yes
Handle_VIA_rport: yes
Insert_VIA_received: yes
Insert_VIA_rport: yes
Substitute_VIA_Addr: yes
Send_Resp_To_Src_Port: yes
STUN_Enable: yes
NAT_Keep_Alive_Intvl: 179

(under Line_1 and Line_2 tabs)
NAT_Mapping_Enable: yes
NAT_Keep_Alive_Enable: yes
NAT_Keep_Alive_Msg: 0000 <-- sometimes just leaving this blank works
NAT_Keep_Alive_Dest: $PROXY
Register Expires: 3600

Sometimes it's preferable to configure the ATA to work without stun. This optional configuration is less easily
portable but allows phone service to continue no matter if the stun server is working.
If you want to do this perform the following steps.

1. Forward the SIP ports and the RTP port range from the router to the ATA.
2. Set "STUN Enable:" no
3. Set "NAT Keep Alive Enable:" no
4. In order for the ATA to know it's public IP address, make sure the ATA is registered with at least one SIP registrar, or enter your public IP address in "EXT IP:".

When done dial *0 or *0# to check that your RTP contact address is correct.