Sangoma A200 analog card hangup detection, UK BT line

Hi. I’ve had Freebpx running with a Sangoma A200 analog card for 3 or 4 years now, but until recently I’ve not been able to configure it to correctly detect when calls hangup on the FXO ports (UK PSTN line, provided by BT’s network). The most annoying problem with this was when people call in, listen to the IVR / Voicemail message and hang up, this was not detected - so you get voicemails consisting of 10 seconds of the continuous 400Hz call disconnected tone.

There’s plenty of info on the forums about trying call progress and tonezones, but this causes other problems and I think this is only applicable to USA phone lines. There’s also some info about contacting BT and getting them to check what your call disconnect clear time is set to and to change it. Good luck getting someone on the phone at BT who knows what your’re talking about!

After a lot of trial and error, I think I’ve finally cracked it. So, if you’re in the same boat, maybe this will help:

This assumes your card is installed and the ports are showing as available in the Analog tab under Connectivity --> Dahdi config in Freepbx. The FXO ports (the ones connected to the telephone exchange) are 3 & 4.
[You might want to make a note of all the original settings before you change them in case you want to revert changes]

  1. Click “Edit” on your FXO ports and check that the Signalling on both are set to Kewl Start.
  2. Click the “Global Settings” button. You need to add the following config statements to the bottom of that page - under Other Global Dahdi Settings - mostly to get caller ID working ok:

cidsignalling=v23
cidstart=polarity
callerid=asreceived
progzone=uk
hanguponpolarityswitch=yes
tonezone=uk

Save and Apply the config.

  1. Now you need to edit the wanpipe config file, so you need to SSH in to your box or secure ftp. I use WinSCP.
  2. The config file gets loaded from /etc/wanpipe/wanpipe1.conf, but this gets recreated by the wanrouter process every time Freepbx starts or dahdi is restarted, so don’t edit it directly.
    Instead, the file you need to edit to stick the changes is /etc/wanpipe/wancfg_zaptel/templates/wanpipe.tdm.a200
  3. Edit the following lines to match and then save (the last two are the most important I believe):

TDMV_LAW = ALAW
TDMV_OPERMODE = TBR21
RM_BATTTHRESH = 4
RM_BATTDEBOUNCE = 4

  1. Restart Freepbx from your SSH console: fwconsole restart

This might work on other analog cards in the UK. My card now detects when the line is hung up, hopefully yours will too! BTW, this is on FreePBX v13.0.197.21
Cheers
Rick

2 Likes

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.