This perl script will allow you to use HTB wondershaper to apply traffic shaping only when an asterisk call is in progress. This allows you to maximise your gateway's available bandwidth without compromising call quality and avoid having upstream/downstream continuously throttled. Only suitable for small offices where phone calls are not constant.