Help with TDM400P, Ast 1.4.24 and FreePBX 2.5.1.2

Hi folks,

I have the following setup:
Asterisk 1.4.24
dahdi-linux (2008-11-02)
FreePBX 2.5.1.2
Centos 5.2
A Digium TDM400P

The system is working fine for making SIP calls but I’ve not yet figured out how to talk to the TDM400P. Since it cost us $400 to buy, I have the boss on my back to make it work :smile: I have a handset plugged into the first port. I have no PSTN connected at this time.

dahdi-linux (and tools) seems to be correctly installed and working. On boot up, I get a number of green lights as modules are installed. On the Asterisk CLI a “dahdi show status” reports a Wildcard TDM400P REV 1 Board 5. A “dahdi show channels” gives a header row but no further info. This seems reasonable to me if there are no active channels.

I have included below some relevant documents. The dahdi-channel.conf and my current extension profile from FreePBX. The conf is auto-generated. I have tried several different values in the Extension profile but haven’t had success yet.

I would appreciate some advice on what values to punch into the extension profile in order to make these lines in and out work OK. And/or any further info on anything else I’m missing. I’ve googled extensively but there seems to be a dearth of documentation on how to configure FreePBX 2.5 for use with DAHDI (vs the older ZAP branded software). Naturally once I get this working, I will publish my findings for all to enjoy :smile:

Thanks,
Sean

Asterisk CLI report

asterisk*CLI> dahdi show status
Description                              Alarms     IRQ        bpviol     CRC4      
Wildcard TDM400P REV I Board 5           OK         0          0          0         
asterisk*CLI> dahdi show channels
   Chan Extension  Context         Language   MOH Interpret       
 pseudo            default                    default             
asterisk*CLI> 

/etc/asterisk/dahdi-channels.conf

; Span 1: WCTDM/4 "Wildcard TDM400P REV I Board 5" (MASTER)
;;; line="1 WCTDM/4/0"
signalling=fxo_ls
callerid="Channel 1" <4001>
mailbox=4001
group=5
context=from-internal
channel => 1
callerid=
mailbox=
group=
context=default

;;; line="2 WCTDM/4/1"
signalling=fxo_ls
callerid="Channel 2" <4002>
mailbox=4002
group=5
context=from-internal
channel => 2
callerid=
mailbox=
group=
context=default

;;; line="3 WCTDM/4/2"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-pstn
channel => 3
callerid=
group=
context=default

;;; line="4 WCTDM/4/3"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-pstn
channel => 4
callerid=
group=
context=default

Ext 100 page from FreePBX

Device Options
This device uses zap technology. (Via DAHDI compatibility mode)
channel 1
context from-internal
immediate no
signalling fxo_ls
echocancel yes
echocancelwhenbridged no
echotraining 800
busydetect no
busycount 7
callprogress no
dial ZAP/1 (have also tried DAHDI/1)
accountcode (blank)
callgroup 5
pickupgroup (blank)
mailbox 4001@device

Here is my chan_dadi.conf (trimmed of comments for brevity)

[trunkgroups]
;
[channels]
context=default
switchtype=national
signalling=fxo_ls
rxwink=300		; Atlas seems to use long (250ms) winks
distinctiveringaftercid=yes	; enable dring detection after callerid for those countries like Australia
usecallerid=yes
hidecallerid=no
callwaiting=yes
usecallingpres=yes
sendcalleridafter=1
callwaitingcallerid=yes
threewaycalling=yes
transfer=yes
canpark=yes
cancallforward=yes
callreturn=yes
echocancel=yes
echocancelwhenbridged=yes
rxgain=0.0
txgain=0.0
group=1
callgroup=1
pickupgroup=1
immediate=no
include chan_dahdi_additional.conf

And the include…

;;;;;;[100]
signalling=fxo_ls
pickupgroup=
mailbox=4001@device
immediate=no
echotraining=800
echocancelwhenbridged=no
echocancel=yes
context=from-internal
callprogress=no
callgroup=5
callerid=device <100>
busydetect=no
busycount=7
accountcode=
channel=>1

;;;;;;[101]
signalling=fxo_ks
pickupgroup=
mailbox=101@device
immediate=no
echotraining=800
echocancelwhenbridged=no
echocancel=yes
context=from-internal
callprogress=no
callgroup=
callerid=device <101>
busydetect=no
busycount=7
accountcode=
channel=>2

And the /etc/dahdi/system.conf

# Autogenerated by /usr/sbin/dahdi_genconf on Tue Mar 24 00:13:03 2009 -- do not hand edit
# Dahdi Configuration File
#
# This file is parsed by the Dahdi Configurator, dahdi_cfg
#
# Span 1: WCTDM/4 "Wildcard TDM400P REV I Board 5" (MASTER) 
fxols=1
echocanceller=mg2,1
fxols=2
echocanceller=mg2,2
fxsks=3
echocanceller=mg2,3
fxsks=4
echocanceller=mg2,4

# Global data

loadzone	= us
defaultzone	= us