The TDM400P is an interface card introduced by Digium. (In early 2003?)

It has up to 4 analog phone line ports on it.

It can be configured with any combinations of station or CO modules by means of mounting daughter cards on the main card. The daughter card for an FXO port is red, the FXS card is green.

The card requires external power to be supplied to it via a standard PC 4-pin Molex power connector, such as the ones that connect to hard disk drives.
The easy way to find out if you have not plugged in your power is to run run 'dmesg |grep -i tdm'

The external connections are four RJ-11 jacks. Port #1 is the one toward the top of the computer (away from the motherboard), Port #4 is the port closet to the motherboard. There is a green LED next to each port.

In the configuration as supplied when purchased as part of the Asterisk developer's kit, the local station line is port #1, the central office line is connected to port #4.

the /etc/zaptel.conf for this looks like:

loadzone = us

What do the LEDs mean? As near as I can determine, the LEDs mean that the Linux kernel has the device drivers loaded for the board. When booting the machine with the card installed, the LEDs remain off until the proper kernel modules are loaded. This is usually done via a "modprobe wctdm". At that stage the LEDs illuminate. Then the 'ztcfg' is run, then asterisk can be started.

When the LEDs illuminate, the card has power, and a station line attached to an fxs port will have 'battery' to it. That is, one can speak into the microphone and hear oneself in the earpiece, and pressing the keypad will generate touch-tones.

If the kernel module loads correctly, something like this appears in /var/log/messages:
Feb 6 12:59:57 pbx kernel: Zapata Telephony Interface Registered on major 196
Feb 6 12:59:59 pbx kernel: Freshmaker version: 71
Feb 6 12:59:59 pbx kernel: Freshmaker passed register test
Feb 6 12:59:59 pbx kernel: Module 0: Installed — AUTO FXS/DPO
Feb 6 12:59:59 pbx kernel: Module 1: Not installed
Feb 6 12:59:59 pbx kernel: Module 2: Not installed
Feb 6 12:59:59 pbx kernel: Module 3: Installed — AUTO FXO (FCC mode)
Feb 6 12:59:59 pbx kernel: Found a Wildcard TDM: Wildcard TDM400P REV E/F (4 modules)

Notice the classic 'off-by-one' here. Channel 1 corresponds to Module 0, Channel 4 to Module 3. Ports are numbered starting with 1, kernel modules are numbered starting with zero.

If the ztcfg goes well, something like the following line will be written to /var/log/messages:
Feb 6 13:00:05 pbx kernel: Registered tone zone 0 (United States / North America)

Another note about the asterisk developer's kit. The contexts of the two channels are inverted in the /etc/asterisk/zapata configuration file. Channel 1, the station line, with signalling fxo should belong in the context "home" not 'bell". Channel 4, the CO line, with signaling fsx should belong to context 'bell', not 'home'.

Loading the wctdm Driver Outside North Amreica

While the TDM400P is certified for many countries, simply specifying the loadzone will not set your card up to suit local line imedences etc. This can lead to echo or bad sound quality even with agressive echo cancelation.

To see the regions supported open the wctdm.c zaptel source file in a text editor. Look for the section starting with:
fxo_modes[] =
{ "FCC", 0, 0, 0, 1, 0, 0x3, 0, 0, }, /* US, Canada */

There are a large number of countries/regions below "FCC". Take note of the exact text for your country or region. eg AUSTRALIA

Taking Australia as an example do the following to load the drivers

modprobe zaptel

modprobe wctdm opermode=AUSTRALIA


and you should see something like:

Mar 23 17:23:51 Asterisk kernel: Module 0: Installed -- AUTO FXO (AUSTRALIA mode)
Mar 23 17:23:51 Asterisk kernel: Module 1: Installed -- AUTO FXO (AUSTRALIA mode)
Mar 23 17:23:51 Asterisk kernel: Module 2: Installed -- AUTO FXO (AUSTRALIA mode)
Mar 23 17:23:51 Asterisk kernel: Module 3: Installed -- AUTO FXO (AUSTRALIA mode)

If you see something like

Mar 23 17:23:51 Asterisk kernel: Module 0: Installed -- AUTO FXO (FCC mode)

then the card is set for North American phone lines.

IMPORTANT 2.6.x kernels will ignore a parameter typed on the command line. You need to add

options wctdm opermode=AUSTRALIA (Using AUSTRALIA as an example)

to /etc/modprobe.d/zaptel

This works in Debian Sarge with 2.6.x kernel. Not sure about other distros


** Incompatible Systems (due to TDM card construction issues) **
7/13/2005 - Dell Poweredge SC420 (Bios A01), Dell Poweredge 750 (Bios A04)

8/2/05 - I have experienced "snap/crackle/pop" on "F" but not "H" version of TDM400P. I have tested on three different models including Dell Dimension 3000.

8/2/2005 - According to Dell, 7th generation machines are incompatible (e.g. PowerEdge SC420, SC430, 750, SC1420, etc.), Dell 8th generation should work fine (e.g. Poweredge 800, 1850, 2850, etc.)
Digium incompatibility notes

8/31/2005 - Does anyone know exactly what these "card construction issues" are? I have shipped several Poweredge SC420s to customers loaded with TDM400P cards and they have worked perfectly. I have some SC430s which I intend to use shortly but haven't tested yet.. they appear to be pretty similar to the SC420s though, so I expect they'll also work. All of the TDM400P cards are marked "FRESHMAKER REV H" on the PCB and "TDM REV F VER36" over the Xilinx chip.

10/25/2005 - Confirmation: using same Rev. H TDM400P's that failed in SC420's and 750 (documented above), run fine in 8th generation Dell Poweredge 830.

11/18/2005 - Side by side test. Two Dell sc1420 computers, one TDM404P FRESHMAKER REV H, one TDM404P FRESHMAKER REV J. I used the same FXO ports (note the TDM404P) in both cards in both machines. I don't know the BIOS rev on each sc1420, but they shipped from Dell at the same time and had identical configurations (I'll update this later). I get snap/crackle/pop sounds during 100% of calls placed or received on Port 1 of the REV J card in both computers, and when using the same FXO ports (I moved them) to the REV H card, I get crystal clear calls on Port 1 of the REV H card in BOTH computers. No other changes. Using 1.0.9 of Asterisk.


NOTE: Common artififacts of various motherboard incompatibilities by the Digium TDM400P are snap/crackle/pop on PSTN calls, and even worse intermittent echo.


TDM400P with Debian Sarge 3.1 Stable using Zaptel 1.2.4

1. Obtain and install Zaptel

Now as an Australian I need to TDM400P to be programmed for Australian line impedance using the option opermode=AUSTRALIA

NOTE: From Zaptel 1.2.4 "opermode=AUSTRALIA" automotically sets the parameters "fxshonormode=1 boostringer=1" for compliance with Australian A-TICK requirements and no longer need to be specified

On Debian stable /etc/modules.conf is dynamically constructed to include all the options for all the kernel drivers and should not be edited.

2. edit /etc/modutils/zaptel and place the line:

options wctdm opermode=AUSTRALIA

anywhere before the line that installs wctdm. On mine I entered the options line near the top before any post-install sections.

3. You have two options for ztcfg. If your /etc/modutils/zaptel has the line "post-install wctdm /sbin/ztcfg" then ztcfg will run after the driver is loaded. You can also add " && /sbin/ztcfg" as in the example below for Fedora kernel 2.6 ie the wctdm driver options string become "options wctdm opermode=AUSTRALIA && /sbin/ztcfg". It doesnt matter which one you use. If you get an error that the zap channel could not be found when asterisk loads this would suggest ztcfg did not run.

4. Back at the shell prompt after saving /etc/modutils/zaptel you now rebuild the autogenerated modules.conf by typing:

You can open /etc/modules.conf to see the options line in place.

5. Load the new driver using:
modprobe zaptel
modprobe wctdm

(modprobe wctdm automatically looks to the /etc/modules.conf for the specified options)

6. Reboot and check /var/log/messages and you should see:
Module 0: Installed — AUTO FXO (AUSTRALIA mode)
Module 1: Installed — AUTO FXO (AUSTRALIA mode)

Note: - if you are running asterisk as non-root you may have to change the ownership and permissions on /dev/zap

TDM400P with Debian Lenny 5.0.3 Stable using Dahdi

The above steps will need to be altered slightly as follows:

2. edit /etc/modprobe.d/dahdi and place line:

options wctdm opermode=AUSTRALIA

4. Back at the shell prompt after saving /etc/modprobe.d/dahdi you now rebuild the modules list by typing:
depmod -a

On Fedora kernel 2.6, use the following method to activate opermode=AUSTRALIA
the "options" paremiter in modprobe.conf did not seem to have an effect but the following does..

In /etc/modprobe.conf modify the following line
install wctdm /sbin/modprobe --ignore-install wctdm && /sbin/ztcfg
install wctdm /sbin/modprobe --ignore-install wctdm opermode=AUSTRALIA && /sbin/ztcfg

If using Zaptel version 1.2.3 or earlier modify to

install wctdm /sbin/modprobe --ignore-install wctdm opermode=AUSTRALIA fxshonormode=1 boostringer=1 && /sbin/ztcfg

NOTE: "fxshonormode=TRUE boostringer=1" is used in Australia for the TDM card to comply with A-TICK approval and is required for Zaptel 1.2.3 and earlier. These options are set automatically when using opermode=AUSTRALIA as from Zaptel 1.2.4. Please check Digium for options for your part of the world.

Line protection

When plugging a PSTN line into your FXO ports, don't forget to think about lightning protection. Lightning strikes on nearby telephone poles or buildings can and will fry your FXO ports, your TDM400 and even your server. You now have a direct copper cable link from the big bad outside world into the heart of your server farm. Many UPS's and power adaptor boards have spike protection circuits you can plug through for one line, or use a dedicated filter bank.

Here's a tip passed on from an old telephone engineer. Where your copper 2-wire cable approaches the building, underground, finish with several large loops, about a metre in diameter, laid on top of each other. Fast moving, high energy spikes will spin off the outside of the loop as they speed into your installation, reducing the amount of energy your spike trap has to absorb. The coil shouldn't have enough loops to create any induction effects.

Where to purchase:

Digium-tdm400p from - In-stock with Free Expert Support! Shop Online or Call 877.434.8647 - Lowest price & Free FedEx 2nd Day Shipping on all TDM400P. Call for reseller pricing. 888-VOIPSTORE. - Best Service! Best Salesman! Best VoIPstore! VoIP and Video Games Free 2 Day Air and Next Day air Available
HUGE Voip - Great deals on Asterisk hardware
NOVACOM Shop Delivery all over Europe. Very competitive prices.
VoIPandGo Quick delivery by UPS. Reseller Prices Available!!
VoIPon Solutions UK & Worldwide USA, Worldwide Distribution
Digium Southeast Asia Digium | Asterisk Authorized Reseller - Digium TDM400P Your one stop VoIP equipment store - TDM400P - Canada

TDM400P- TDM400P Asterisk card

28th May 2005 - Digium have released a brand new version of the FXO module for the Digium Wildcard TDM400P which is now officially UK approved. UK customers can get them from MyPhoneCall

See also

Created by: ibrent, Last modification: Thu 16 of Aug, 2012 (16:11 UTC) by e4strategies1
Please update this page with new information, just login and click on the "Edit" or "Discussion" tab. Get a free login here: Register Thanks! - Find us on Google+